3 ms·
What is it with people pushing the c style "->" everywhere. Dot works just fine, is just one char, no shift key required and it is still unambiguous. Stop this
by dmz73 5y ago
What is it with people pushing the c style "->" everywhere. Dot works just fine, is just one char, no shift key required and it is still unambiguous. Stop this "->" nonsense. Even in c it shouldn't be required, the intent is clear and unambiguous if dot is used.
- JoelJacobson 5y agoSince dot "." is already used to refer to columns, reusing it to refer to foreign keys would make parsing a lot more complex and error-prone, since the grammar would be context-sensitive, you would need to take into account you are parsing a foreign key join expression first, i.e. you wouldn't know what "foo->bar" meant without looking at the surrounding code. While probably possible, I think it would be less clear and also increase parser complexity more than necessary. My original idea was actually to use dot ".", but then others explained the above to me, which made me rethink.
- CRConrad 5y ago> Since dot "." is already used to refer to columns But is it really? If you think of it as referencing "some attribute of whatever is mentioned before it", the period could also refer to constraints, indexes, or whatever.