aboutsummaryrefslogtreecommitdiff
path: root/src/include
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2007-01-03 22:39:26 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2007-01-03 22:39:26 +0000
commitd6061d2f31187795790e7e63d5d9730f9d78e7ea (patch)
tree15cd6bd72dbb5fece8ba93c0322e41059c788aee /src/include
parent9c88830ec495e76a4ebba4bde01989241e8d145a (diff)
downloadpostgresql-d6061d2f31187795790e7e63d5d9730f9d78e7ea.tar.gz
postgresql-d6061d2f31187795790e7e63d5d9730f9d78e7ea.zip
Fix regex_fixed_prefix() to cope reasonably well with regex patterns of the
form '^(foo)$'. Before, these could never be optimized into indexscans. The recent changes to make psql and pg_dump generate such patterns (for \d commands and -t and related switches, respectively) therefore represented a big performance hit for people with large pg_class catalogs, as seen in recent gripe from Erik Jones. While at it, be more paranoid about case-sensitivity checking in multibyte encodings, and fix some other corner cases in which a regex might be interpreted too liberally.
Diffstat (limited to 'src/include')
-rw-r--r--src/include/utils/builtins.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/include/utils/builtins.h b/src/include/utils/builtins.h
index 56e63d7f73c..170fa28ca8d 100644
--- a/src/include/utils/builtins.h
+++ b/src/include/utils/builtins.h
@@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2006, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $PostgreSQL: pgsql/src/include/utils/builtins.h,v 1.283 2006/12/30 21:21:55 tgl Exp $
+ * $PostgreSQL: pgsql/src/include/utils/builtins.h,v 1.284 2007/01/03 22:39:26 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -477,6 +477,7 @@ extern Datum textregexsubstr(PG_FUNCTION_ARGS);
extern Datum textregexreplace_noopt(PG_FUNCTION_ARGS);
extern Datum textregexreplace(PG_FUNCTION_ARGS);
extern Datum similar_escape(PG_FUNCTION_ARGS);
+extern bool regex_flavor_is_basic(void);
/* regproc.c */
extern Datum regprocin(PG_FUNCTION_ARGS);