You can always put a unique index on those 2 columns to prevent duplicates.
>From a db perspective your composite primary key makes sense. But from an entity/object/php perspective it's perfectly normal to give an entity an explicit identifier. It also makes dealing with those entities a lot simpler. PS: I do hope you're going to try it in order to rule out the composite primary key is the problem, and report a bug with a reproducible test-case to help maintainers improve Doctrine :) -- Jasper N. Brouwer (@jaspernbrouwer) On 12 Jan 2014, at 22:42, [email protected] wrote: > Thanks Jasper for your answers. > > For your workaround i don't really love the way to remove my combine ids > because it avoid having multiple rows with same 'keys'. > Well i will try keep my extra query at the moment. > > For the pro tip i'm gone use it thanks ! > > Have a nice day and thanks again ;) > > Best regards, > David. -- You received this message because you are subscribed to the Google Groups "doctrine-user" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/doctrine-user. For more options, visit https://groups.google.com/groups/opt_out.
