summaryrefslogtreecommitdiff
path: root/src/backend/utils/adt/regexp.c
AgeCommit message (Collapse)Author
2004-05-07Solve the 'Turkish problem' with undesirable locale behavior for caseTom Lane
conversion of basic ASCII letters. Remove all uses of strcasecmp and strncasecmp in favor of new functions pg_strcasecmp and pg_strncasecmp; remove most but not all direct uses of toupper and tolower in favor of pg_toupper and pg_tolower. These functions use the same notions of case folding already developed for identifier case conversion. I left the straight locale-based folding in place for situations where we are just manipulating user data and not trying to match it to built-in strings --- for example, the SQL upper() function is still locale dependent. Perhaps this will prove not to be what's wanted, but at the moment we can initdb and pass regression tests in Turkish locale.
2004-02-03pwdTom Lane
2004-01-19Repair problem identified by Olivier Prenant: ALTER DATABASE SET search_pathTom Lane
should not be too eager to reject paths involving unknown schemas, since it can't really tell whether the schemas exist in the target database. (Also, when reading pg_dumpall output, it could be that the schemas don't exist yet, but eventually will.) ALTER USER SET has a similar issue. So, reduce the normal ERROR to a NOTICE when checking search_path values for these commands. Supporting this requires changing the API for GUC assign_hook functions, which causes the patch to touch a lot of places, but the changes are conceptually trivial.
2003-11-29$Header: -> $PostgreSQL Changes ...PostgreSQL Daemon
2003-08-08Another pgindent run with updated typedefs.Bruce Momjian
2003-08-04Update copyrights to 2003.Bruce Momjian
2003-08-04pgindent run.Bruce Momjian
2003-07-27Error message editing in utils/adt. Again thanks to Joe Conway for doingTom Lane
the bulk of the heavy lifting ...
2003-02-06Create a GUC variable REGEX_FLAVOR to control the type of regularTom Lane
expression accepted by the regex operators, per discussion yesterday. Along the way, reduce deadlock_timeout from PGC_POSTMASTER to PGC_SIGHUP category. It is probably best to insist that all backends share the same setting, but that doesn't mean it has to be frozen at startup.
2003-02-05Replace regular expression package with Henry Spencer's latest versionTom Lane
(extracted from Tcl 8.4.1 release, as Henry still hasn't got round to making it a separate library). This solves a performance problem for multibyte, as well as upgrading our regexp support to match recent Tcl and nearly match recent Perl.
2002-09-22Bring SIMILAR TO and SUBSTRING into some semblance of conformance withTom Lane
the SQL99 standard. (I'm not sure that the character-class features are quite right, but that can be fixed later.) Document SQL99 and POSIX regexps as being different features; provide variants of SUBSTRING for each.
2002-09-04pgindent run.Bruce Momjian
2002-06-20Update copyright to 2002.Bruce Momjian
2002-06-15Search the existing regular expression cache as a ring buffer.Thomas G. Lockhart
Will optimize the case for repeated calls for the same expression, which seems to be the most common case. Formerly, always searched from the first entry. May want to look at the least-recently-used algorithm to make sure it is identifying the right slots to reclaim. Seems silly to do math when it seems that we could simply use an incrementing counter...
2002-06-11Implement SQL99 OVERLAY(). Allows substitution of a substring in a string.Thomas G. Lockhart
Implement SQL99 SIMILAR TO as a synonym for our existing operator "~". Implement SQL99 regular expression SUBSTRING(string FROM pat FOR escape). Extend the definition to make the FOR clause optional. Define textregexsubstr() to actually implement this feature. Update the regression test to include these new string features. All tests pass. Rename the regular expression support routines from "pg95_xxx" to "pg_xxx". Define CREATE CHARACTER SET in the parser per SQL99. No implementation yet.
2001-11-05New pgindent run with fixes suggested by Tom. Patch manually reviewed,Bruce Momjian
initdb/regression tests pass.
2001-10-25pgindent run on all C files. Java run to follow. initdb/regressionBruce Momjian
tests pass.
2001-03-22pgindent run. Make it all clean.Bruce Momjian
2001-03-19Make regular-expression error messages a tad less obscure,Tom Lane
per gripe from Josh Berkus.
2001-01-24Change Copyright from PostgreSQL, Inc to PostgreSQL Global Development Group.Bruce Momjian
2000-07-07Fix misuse of StrNCpy to copy and add null to non-null-terminated data.Tom Lane
Does not work since it fetches one byte beyond the source data, and when the phase of the moon is wrong, the source data is smack up against the end of backend memory and you get SIGSEGV. Don't laugh, this is a fix for an actual user bug report.
2000-07-06Functions on 'text' type updated to new fmgr style. 'text' isTom Lane
now TOAST-able.
2000-07-05Update textin() and textout() to new fmgr style. This is just phaseTom Lane
one of updating the whole text datatype, but there are so dang many calls of these two routines that it seems worth a separate commit.
2000-01-26Add:Bruce Momjian
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc to all files copyright Regents of Berkeley. Man, that's a lot of files.
1999-11-07New NameStr macro to convert Name to Str. No need for var.data anymore.Bruce Momjian
Fewer calls to nameout. Better use of RelationGetRelationName.
1999-07-17 Move some system includes into c.h, and remove duplicates.Bruce Momjian
1999-07-16Final cleanup.Bruce Momjian
1999-07-16Update #include cleanupsBruce Momjian
1999-07-15Change #include's to use <> and "" as appropriate.Bruce Momjian
1999-07-15Clean up #include in /include directory. Add scripts for checking includes.Bruce Momjian
1999-07-14Cleanup of /include #include's, for 6.6 only.Bruce Momjian
1999-02-13Change my-function-name-- to my_function_name, and optimizer renames.Bruce Momjian
1999-02-03Cleanup of source files where 'return' or 'var =' is alone on a line.Bruce Momjian
1998-09-01OK, folks, here is the pgindent output.Bruce Momjian
1998-09-01Renaming cleanup, no pgindent yet.Bruce Momjian
1998-06-15Remove un-needed braces around single statements.Bruce Momjian
1998-04-26Re-apply Darren's char2-16 removal code.Bruce Momjian
1998-04-07Back out char2-char16 removal. Add later.Bruce Momjian
1998-03-30The following uuencoded, gzip'd file will ...Bruce Momjian
1. Remove the char2, char4, char8 and char16 types from postgresql 2. Change references of char16 to name in the regression tests. 3. Rename the char16.sql regression test to name.sql. 4. Modify the regression test scripts and outputs to match up. Might require new regression.{SYSTEM} files... Darren King
1998-02-26pgindent run before 6.3 release, with Thomas' requested changes.Bruce Momjian
1998-01-05Change some ABORTS to ERROR. Add line number when COPY Failure.Bruce Momjian
1998-01-05Change elog(WARN) to elog(ERROR) and elog(ABORT).Bruce Momjian
1997-10-25Rename strNcpy to StrNCpy, and change third parameter.Bruce Momjian
1997-09-08Used modified version of indent that understands over 100 typedefs.Bruce Momjian
1997-09-08Another PGINDENT run that changes variable indenting and case label ↵Bruce Momjian
indenting. Also static variable indenting.
1997-09-07Massive commit to run PGINDENT on all *.c and *.h files.Bruce Momjian
1997-08-12Remove more (void) and fix -Wall warnings.Bruce Momjian
1997-08-12Fix pgproc names over 15 chars in output. Add strNcpy() function. remove ↵Bruce Momjian
some (void) casts that are unnecessary.
1996-11-10Remove #include <regex.h> so it compiles on systems with GNU regex library.Bryan Henderson
1996-11-06Another directory that compiles with no errors, and few warningsMarc G. Fournier