1
0
mirror of https://github.com/postgres/postgres.git synced 2025-06-11 20:28:21 +03:00

Add more info on regex's using INDEX.

This commit is contained in:
Bruce Momjian
2002-06-25 03:32:31 +00:00
parent 20241a4c54
commit c1e2f351f8
2 changed files with 44 additions and 13 deletions

20
doc/FAQ
View File

@ -1,7 +1,7 @@
Frequently Asked Questions (FAQ) for PostgreSQL
Last updated: Mon Jun 24 21:45:50 EDT 2002
Last updated: Mon Jun 24 23:32:16 EDT 2002
Current maintainer: Bruce Momjian (pgman@candle.pha.pa.us)
@ -747,10 +747,20 @@
LIMIT 1
When using wild-card operators such as LIKE or ~, indexes can only be
used if the default C local is used during initdb and the beginning of
the search is anchored to the start of the string. Therefore, to use
indexes, LIKE patterns must not start with %, and ~(regular
expression) patterns must start with ^.
used in certain circumstances:
* The beginning of the search string must be anchored to the start
of the string, i.e.:
* LIKE patterns must not start with %.
* ~(regular expression) patterns must start with ^.
The search string can not start with a character class, e.g. [a-e].
Case-insensitive searches like ILIKE and ~* can not be used.
Instead, use functional indexes, which are described later in this
FAQ.
The default C local must have been used during initdb.
4.9) How do I see how the query optimizer is evaluating my query?