Why does the primary key allow for duplicates?
That said, the _id column, which is also a primary key, does prevent duplicates.
I’m trying to prevent duplicate emails for one of my tables.
Why does the primary key allow for duplicates?
That said, the _id column, which is also a primary key, does prevent duplicates.
I’m trying to prevent duplicate emails for one of my tables.
Brett, what Wix calls a Primary Key !== primary key in its accepted meaning. Wix´s Primary Key should have been called “Unique Display Key for Content Manager Only” or something likewise.
A short breakdown:
In short: Wix Primary Key only has a meaning inside Content Manager, it´s not a Primary Key (but _id is), it is NOT NO_DUPS, and yes, the name Primary Key is extremely confusing (coming from relational db´s).
Does this make any sense? It took me quite a while to figure this out, hope it helps.