i'm new in django/python. I have a function in the code that my boss gave to me that creates a new table everyday since 2012 using a static table as a model. So, my question is: How can i retrieve the data of the daily tables using the static table? Something like:
models.py
class report_2015_03_20(models.Model):
name = models.CharField(max_length=50)
class Meta:
managed = False
db_table = 'report_2015_03_20'
class report_2015_03_21(models.Model):
name = models.CharField(max_length=50)
class Meta:
managed = False
db_table = 'report_2015_03_20'
class report_2015_03_22(models.Model):
name = models.CharField(max_length=50)
class Meta:
managed = False
db_table = 'report_2015_03_20'
And i need to consult passing meta as a parameter:
class report(models.Model):
name = models.CharField(max_length=50)
class Meta:
db_table = 'report_x_x_x'
Any help or ideia will me nice. Thanks