|
|
|
|
|
by paozac
1641 days ago
|
|
Not sure about this, I wouldn't like having to look up the FK name every time or hope it was named following the convention. The first thing (among many others) that I would change in SQL is the position of the SELECT clause: FROM .. JOIN .. SELECT .. WHERE .. instead of SELECT .. FROM .. JOIN .. WHERE .. That would make the construction of many queries more natural. |
|
So if we could rewrite history, I agree the order you suggest would make more sense, but it’s probably unrealistic to change it, except for entirely new SQL inspired languages.
To comment on having to look up foreign keys. The idea I had in mind is to allow changing the default formatting of foreign key names, so you could figure out the name, except in special cases such as if there would be two foreign keys referencing the same table. For such cases you should explicitly name the foreign keys.