(no title)
ewang1 | 10 years ago
The solution the problem you described would be to use a surrogate key column (typically a UUID/auto-increment), and not natural keys.
ewang1 | 10 years ago
The solution the problem you described would be to use a surrogate key column (typically a UUID/auto-increment), and not natural keys.
jsprogrammer|10 years ago
All tables had a unique, integer primary key.
However, if you want to enforce a uniqueness constraint across your data [eg. UNIQUE(name, location)], the constraint breaks when you introduce the boolean deleted column [and UNIQUE(name, location, deleted) does not provide the appropriate semantics]. The application semantics must be provided at some other level than SQL column constraints.