Re: [HACKERS] Non-C locale and LIKE

2004-11-28 Thread Bruce Momjian
Peter Eisentraut wrote: > Bruce Momjian wrote: > > However, I am wondering if we should create a character lookup during > > initdb that has the characters ordered so we can do: > > That won't work. Real-life collations are too complicated. OK. > > Also, we mention you should use the "C" locale

Re: [HACKERS] Non-C locale and LIKE

2004-11-28 Thread Peter Eisentraut
Bruce Momjian wrote: > However, I am wondering if we should create a character lookup during > initdb that has the characters ordered so we can do: That won't work. Real-life collations are too complicated. > Also, we mention you should use the "C" locale to use normal indexes > for LIKE but isn

Re: [HACKERS] Non-C locale and LIKE

2004-11-28 Thread Tatsuo Ishii
> I know we can't currently use an index with non-C locales and LIKE > except when we create a sepcial type of index for LIKE indexing > (text_pattern_ops). > > However, I am wondering if we should create a character lookup during > initdb that has the characters ordered so we can do: > > c

Re: [HACKERS] Non-C locale and LIKE

2004-11-27 Thread John Hansen
> However, I am wondering if we should create a character > lookup during initdb that has the characters ordered so we can do: > > col LIKE 'ha%' AND col >= "ha" and col <= "hb" > > Could we do this easily for single-character encodings? We > could have: > > A 1 > B

[HACKERS] Non-C locale and LIKE

2004-11-27 Thread Bruce Momjian
I know we can't currently use an index with non-C locales and LIKE except when we create a sepcial type of index for LIKE indexing (text_pattern_ops). However, I am wondering if we should create a character lookup during initdb that has the characters ordered so we can do: col LIKE 'ha%'