Edward Macnaghten wrote:
I use column names. I have created a wrapper around sqlite3 (and other SQL engines) in a developmeny environment I have written to enable the programmer (or user for that matter) to access an SQL result set using an object where the property names are the column names.
Same here -- loading row data into a hash and using column names to access values.
However - having duplicate column names (without aliasing them), or using an unqualified "*" when querying a select statement with more than one table in it is really bad practice - and I do not think the ANSI standard specifies how that should be dealt with so I do not think sqlite CAN do it "wrong" in that case.
My view is that of trying to avoid having duplicate column names in the first place (when designing schemas), but
more importantly I am always wary of using * in the first place unless its throw away SQL in a GUI client that can
handle all these things and more importantly where I won't care about exact column name conflicts as I select data for
visual purposes.
regards
Alex