Andrew Dunstan <[EMAIL PROTECTED]> writes:
> I am also wondering if it might be sensible to make this choice once at 
> backend startup and store a function pointer, instead of doing it for 
> every string processed by like/ilike:

>     if (pg_database_encoding_max_length() == 1)
>         return SB_MatchText(s, slen, p, plen);
>     else if (GetDatabaseEncoding() == PG_UTF8)
>         return UTF8_MatchText(s, slen, p, plen);
>     else
>         return MB_MatchText(s, slen, p, plen);

> I guess that might make matters harder if we ever got per-column encodings.

Yeah.  It's not saving much anyway ... I wouldn't bother.

                        regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 1: if posting/reading through Usenet, please send an appropriate
       subscribe-nomail command to [EMAIL PROTECTED] so that your
       message can get through to the mailing list cleanly

Reply via email to