Re: SELECT ... WHERE ... NOT IN (SELECT ...);

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: SELECT ... WHERE ... NOT IN (SELECT ...);
Дата
Msg-id 19392.1030109144@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: SELECT ... WHERE ... NOT IN (SELECT ...);  (Yon Den Baguse Ngarso <yon@dugem.com>)
Ответы Re: SELECT ... WHERE ... NOT IN (SELECT ...);  ("Ross J. Reedstrom" <reedstrm@rice.edu>)
Список pgsql-sql
Yon Den Baguse Ngarso <yon@dugem.com> writes:
> If i create tbl1 & tbl2, and then load it with the data.
> The result is CORRECT. Like yours.
> But, if the data loaded from another table, the result become WRONG/ null record. 

Do you have any nulls in what you are selecting into tbl2?
The behavior of NOT IN with nulls is not very intuitive.
        regards, tom lane


В списке pgsql-sql по дате отправления:

Предыдущее
От: Andreas Tille
Дата:
Сообщение: Updatable View (Was: Separating data sets in a table)
Следующее
От: "Ross J. Reedstrom"
Дата:
Сообщение: Re: SELECT ... WHERE ... NOT IN (SELECT ...);