No error when column doesn't exist
| От | Dean Rasheed |
|---|---|
| Тема | No error when column doesn't exist |
| Дата | |
| Msg-id | BAY102-W9B6A6BCCA4DD85B34F56CF2570@phx.gbl обсуждение исходный текст |
| Ответы |
Re: No error when column doesn't exist
|
| Список | pgsql-general |
I've just spent a couple of hours tracking down a bug which turned out to be a typo in my code. What surprises me is that the SQL in question didn't immediately produce an error. Here's a simplified example: CREATE TABLE foo(a int, b int); INSERT INTO foo VALUES(1,2); SELECT foo.text FROM foo; I expected that to generate an error: column foo.text does not exist. Instead it treats "foo.text" as "foo.*::text AS text": SELECT foo.text FROM foo; text ------- (1,2) (1 row) If foo actually does have a column called text, this works as expected, selecting just that column. Is this a feature or a bug? Dean _________________________________________________________________ Make a mini you and download it into Windows Live Messenger http://clk.atdmt.com/UKM/go/111354029/direct/01/
В списке pgsql-general по дате отправления: