Re: Like vs '=' bug with indexing
От | Tom Lane |
---|---|
Тема | Re: Like vs '=' bug with indexing |
Дата | |
Msg-id | 4392.981239269@sss.pgh.pa.us обсуждение исходный текст |
Ответ на | Re: Like vs '=' bug with indexing (m w <mttf2000@yahoo.com>) |
Ответы |
Re: Like vs '=' bug with indexing
|
Список | pgsql-hackers |
m w <mttf2000@yahoo.com> writes: > I think this exposes a bug in postgres where either > index or table scans (I'm not sure which just yet) > treat a zero differently than a non-zero in a varchar. Embedded zeroes aren't supported in char/varchar/text fields, and cannot be supported in a portable fashion, since these datatypes rely on functions like strcoll() that don't allow embedded nulls in strings. It wouldn't surprise me too much if there are inconsistent behaviors between indexscans and seqscans for such invalid data. It doesn't seem real practical for us to examine the output of every C-coded function to make sure it produces a valid value of the datatype. Illegal returned values are a fault of the function, and ensuing misbehaviors are still its fault ... regards, tom lane
В списке pgsql-hackers по дате отправления: