Monday, July 29, 2013

django workaround for multiple primary keys or sqlalchemy

Hi all,

i'm fairly new to Django and i have a question regarding the best practice for a situation i've got.

I'm working on a new project and after designing my ERD I know i need a few tables to have multiple primary keys and one table with triple primary keys.

after reading about the subject online i found out that Django does not support this feature yet but there is a workaround which is to add a unique_together constraint (if i understand correct)
reading some more online there are recommendations for working with SQLAlchemy that does support the multiple primary key issue.

I have 2 questions regarding those issues:
1. if I use the django workaround will it later bite me in the ass performance wise and simply by not working correctly?
2. if i'll work with SQLAlchemy does that mean that i wont be able to work with django models and all that is derived from working like so?

whats the recommended practice for my situation?

Thanks all..

--
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+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

No comments:

Post a Comment