why these results?

Поиск
Список
Период
Сортировка
От Wes James
Тема why these results?
Дата
Msg-id CAFjCMHuntvFO7SsGYNQrDjUwXazfnu5dgYA0BOh4eX0VcABzeA@mail.gmail.com
обсуждение исходный текст
Ответы Re: why these results?  (Adrian Klaver <adrian.klaver@gmail.com>)
Re: why these results?  (Reinoud van Leeuwen <reinoud.v@n.leeuwen.net>)
Re: why these results?  (Steve Crawford <scrawford@pinpointresearch.com>)
Список pgsql-sql
select count(*) from table;

count
-------  100
(1 row)


is correct

select count(*) from table where col::text ~~* '%text%';

count
-------    1
(1 row)

is correct.

But now if I do:


select count(*) from table where col::text !~~* '%text%';
count
------- 98
(1 row)

Shouldn't it be 99?  That is out of 100 records there is one that has
"text" in column "col" so the !~~* should return 99 rows.  ??

-wes


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

Предыдущее
От: James Kitambara
Дата:
Сообщение: ...
Следующее
От: Adrian Klaver
Дата:
Сообщение: Re: why these results?