diff options
| author | Tom Lane | 2008-07-03 20:58:47 +0000 |
|---|---|---|
| committer | Tom Lane | 2008-07-03 20:58:47 +0000 |
| commit | c63147d6f0e86d96ffb315147f36af613a35c2ce (patch) | |
| tree | ab767c9fa14153d7fafd45d7fa1350d50265ab89 /src/include | |
| parent | e3d9dceef62e072cf9a433ae6c74a1c5a10d94d3 (diff) | |
Add a function pg_get_keywords() to let clients find out the set of keywords
known to the SQL parser. Dave Page
Diffstat (limited to 'src/include')
| -rw-r--r-- | src/include/catalog/catversion.h | 4 | ||||
| -rw-r--r-- | src/include/catalog/pg_proc.h | 5 | ||||
| -rw-r--r-- | src/include/parser/keywords.h | 5 | ||||
| -rw-r--r-- | src/include/utils/builtins.h | 3 |
4 files changed, 12 insertions, 5 deletions
diff --git a/src/include/catalog/catversion.h b/src/include/catalog/catversion.h index a49beccd54f..e7ba550c484 100644 --- a/src/include/catalog/catversion.h +++ b/src/include/catalog/catversion.h @@ -37,7 +37,7 @@ * Portions Copyright (c) 1996-2008, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/catalog/catversion.h,v 1.464 2008/06/24 17:58:27 tgl Exp $ + * $PostgreSQL: pgsql/src/include/catalog/catversion.h,v 1.465 2008/07/03 20:58:46 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -53,6 +53,6 @@ */ /* yyyymmddN */ -#define CATALOG_VERSION_NO 200806241 +#define CATALOG_VERSION_NO 200807031 #endif diff --git a/src/include/catalog/pg_proc.h b/src/include/catalog/pg_proc.h index dbe79102822..09700e8f43a 100644 --- a/src/include/catalog/pg_proc.h +++ b/src/include/catalog/pg_proc.h @@ -7,7 +7,7 @@ * Portions Copyright (c) 1996-2008, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/catalog/pg_proc.h,v 1.503 2008/06/17 19:10:56 tgl Exp $ + * $PostgreSQL: pgsql/src/include/catalog/pg_proc.h,v 1.504 2008/07/03 20:58:46 tgl Exp $ * * NOTES * The script catalog/genbki.sh reads this file and generates .bki @@ -2288,6 +2288,9 @@ DESCR("deparse an encoded expression"); DATA(insert OID = 1665 ( pg_get_serial_sequence PGNSP PGUID 12 1 0 f f t f s 2 25 "25 25" _null_ _null_ _null_ pg_get_serial_sequence - _null_ _null_ )); DESCR("name of sequence for a serial column"); +DATA(insert OID = 1686 ( pg_get_keywords PGNSP PGUID 12 10 400 f f t t s 0 2249 "" "{25,18,25}" "{o,o,o}" "{word,catcode,catdesc}" pg_get_keywords - _null_ _null_ )); +DESCR("list of SQL keywords"); + /* Generic referential integrity constraint triggers */ DATA(insert OID = 1644 ( RI_FKey_check_ins PGNSP PGUID 12 1 0 f f t f v 0 2279 "" _null_ _null_ _null_ RI_FKey_check_ins - _null_ _null_ )); diff --git a/src/include/parser/keywords.h b/src/include/parser/keywords.h index 717e20e7df4..2da7fd3da9e 100644 --- a/src/include/parser/keywords.h +++ b/src/include/parser/keywords.h @@ -7,7 +7,7 @@ * Portions Copyright (c) 1996-2008, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/parser/keywords.h,v 1.24 2008/01/01 19:45:58 momjian Exp $ + * $PostgreSQL: pgsql/src/include/parser/keywords.h,v 1.25 2008/07/03 20:58:46 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -28,6 +28,9 @@ typedef struct ScanKeyword int16 category; /* see codes above */ } ScanKeyword; +extern const ScanKeyword ScanKeywords[]; +extern const ScanKeyword *LastScanKeyword; + extern const ScanKeyword *ScanKeywordLookup(const char *text); #endif /* KEYWORDS_H */ diff --git a/src/include/utils/builtins.h b/src/include/utils/builtins.h index c34ee7aa904..2abbe667891 100644 --- a/src/include/utils/builtins.h +++ b/src/include/utils/builtins.h @@ -7,7 +7,7 @@ * Portions Copyright (c) 1996-2008, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/utils/builtins.h,v 1.317 2008/06/17 19:10:56 tgl Exp $ + * $PostgreSQL: pgsql/src/include/utils/builtins.h,v 1.318 2008/07/03 20:58:47 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -411,6 +411,7 @@ extern Datum pg_reload_conf(PG_FUNCTION_ARGS); extern Datum pg_tablespace_databases(PG_FUNCTION_ARGS); extern Datum pg_rotate_logfile(PG_FUNCTION_ARGS); extern Datum pg_sleep(PG_FUNCTION_ARGS); +extern Datum pg_get_keywords(PG_FUNCTION_ARGS); /* oid.c */ extern Datum oidin(PG_FUNCTION_ARGS); |
