Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Generating script for Unmaaged model. #23

Open
saran-greytip opened this issue Jun 19, 2024 · 0 comments
Open

Generating script for Unmaaged model. #23

saran-greytip opened this issue Jun 19, 2024 · 0 comments

Comments

@saran-greytip
Copy link

saran-greytip commented Jun 19, 2024

This package generates the SQL script for the unmanaged model as well. Whereas the Django migrate command ignore creating tables for the un-managed model

For eg below is the un-managed model. Ideally SQL script should not be created for this model as managed = False used in the class Meta.

class PollListingView(models.Model):
    id = models.UUIDField(primary_key=True)
    title = models.CharField(max_length=128, null=False, db_index=True)
    status = models.CharField(max_length=16, default='unapproved')
    class Meta:
        managed = False
        db_table = 'poll_listing_view'    
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant