[GENERAL] OTICE: adding missing FROM-clause entry for table

2005-08-12 Thread Christian Laursen
I just experienced some bad SQL causing quite unexpected results. I used a statement like this: SELECT t1.a, t1.b, t2.d FROM test1 t1, test2 t2 WHERE t1.a = test2.a; Where I should have used this instead: SELECT t1.a, t1.b, t2.d FROM test1 t1, test2 t2 WHERE t1.a = t2.a; When I looked into it

Re: [GENERAL] OTICE: adding missing FROM-clause entry for table

2005-08-12 Thread Roman Neuhauser
# [EMAIL PROTECTED] / 2005-08-12 10:17:50 +0200: I just experienced some bad SQL causing quite unexpected results. I used a statement like this: SELECT t1.a, t1.b, t2.d FROM test1 t1, test2 t2 WHERE t1.a = test2.a; Where I should have used this instead: SELECT t1.a, t1.b, t2.d FROM test1

Re: [GENERAL] OTICE: adding missing FROM-clause entry for table

2005-08-12 Thread Richard Huxton
Christian Laursen wrote: When I looked into it and tried it from psql, I got this notice: NOTICE: adding missing FROM-clause entry for table test2 Now, I understand that postgresql is adding test2 to the list of tables, I am selecting from as it is missing. However the result is quite