want to create multiple tables for the same app in Django

432 views
Skip to first unread message

Pawan Kumar

unread,
Jan 29, 2020, 2:13:36 PM1/29/20
to Django users
Hi Team,

I want to create multiple tables for the same app in Django & data from these tables is required to be shown in multiple html pages . 
My existing table using models.py is  ...


from django.db import models
# Create your models here.

class IAM(models.Model):
    node = models.CharField(max_length=50)
    status = models.CharField(max_length=50)
    component = models.CharField(max_length=100)
    dbversion = models.CharField(max_length=50)
    version_no = models.CharField(max_length=50)
    dbversion = models.CharField(max_length=50)
    def __str__(self):
        return self.component

maninder singh Kumar

unread,
Jan 30, 2020, 5:35:05 AM1/30/20
to django...@googlegroups.com
Write as many models for tables reqd in db
What is the problem you are facing ?
Could it be the tables don't appear in all HTML!

Sent from my iPad
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/4a302377-62eb-4de7-a451-caf58f46d41d%40googlegroups.com.

Pawan Kumar

unread,
Feb 2, 2020, 11:24:41 PM2/2/20
to Django users
Thanks Team,

Definitely i am able to create multiple tables using models . 
But I was planning to implement a solution with following scenario--

I have 16 different tables & these can be rendered to multiple html pages .
Is it possible to render particular table on single page dynamically , means if i click on particular href link  a particular table is fetched . 


warm regards
Pawan kumar

On Thursday, January 30, 2020 at 4:05:05 PM UTC+5:30, maninder singh Kumar wrote:
Write as many models for tables reqd in db
What is the problem you are facing ?
Could it be the tables don't appear in all HTML!

Sent from my iPad

On 29-Jan-2020, at 9:32 PM, Pawan Kumar <pawa...@gmail.com> wrote:

Hi Team,

I want to create multiple tables for the same app in Django & data from these tables is required to be shown in multiple html pages . 
My existing table using models.py is  ...


from django.db import models
# Create your models here.

class IAM(models.Model):
    node = models.CharField(max_length=50)
    status = models.CharField(max_length=50)
    component = models.CharField(max_length=100)
    dbversion = models.CharField(max_length=50)
    version_no = models.CharField(max_length=50)
    dbversion = models.CharField(max_length=50)
    def __str__(self):
        return self.component

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django...@googlegroups.com.

Suraj Thapa FC

unread,
Feb 3, 2020, 12:45:33 AM2/3/20
to django...@googlegroups.com
You must be trolling... 
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/a0d839f5-0a64-447c-918e-6198d267e81c%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages