aboutsummaryrefslogtreecommitdiff
path: root/src/interfaces
diff options
context:
space:
mode:
authorMarc G. Fournier <scrappy@hub.org>1998-08-25 21:37:08 +0000
committerMarc G. Fournier <scrappy@hub.org>1998-08-25 21:37:08 +0000
commitf62d1253eff4622f6ff0b76f8f0f2eca793bd608 (patch)
treee28e49785256ce9f46f924bc518b0dfeda0d80a6 /src/interfaces
parent7414d619507ed9e2cdb5113ff77df55feef786c4 (diff)
downloadpostgresql-f62d1253eff4622f6ff0b76f8f0f2eca793bd608.tar.gz
postgresql-f62d1253eff4622f6ff0b76f8f0f2eca793bd608.zip
From: Massimo Dal Zotto <dz@cs.unitn.it>
> these patches define the UNLISTEN sql command. The code already > existed but it was unknown to the parser. Now it can be used > like the listen command. > You must make clean and delete gram.c and parser.h before make.
Diffstat (limited to 'src/interfaces')
-rw-r--r--src/interfaces/ecpg/preproc/keywords.c3
-rw-r--r--src/interfaces/ecpg/preproc/preproc.y9
2 files changed, 10 insertions, 2 deletions
diff --git a/src/interfaces/ecpg/preproc/keywords.c b/src/interfaces/ecpg/preproc/keywords.c
index 9f953cb98f5..a17455de3fe 100644
--- a/src/interfaces/ecpg/preproc/keywords.c
+++ b/src/interfaces/ecpg/preproc/keywords.c
@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/interfaces/ecpg/preproc/keywords.c,v 1.2 1998/05/18 16:05:00 scrappy Exp $
+ * $Header: /cvsroot/pgsql/src/interfaces/ecpg/preproc/keywords.c,v 1.3 1998/08/25 21:37:06 scrappy Exp $
*
*-------------------------------------------------------------------------
*/
@@ -201,6 +201,7 @@ static ScanKeyword ScanKeywords[] = {
{"type", TYPE_P},
{"union", UNION},
{"unique", UNIQUE},
+ {"unlisten", UNLISTEN},
{"until", UNTIL},
{"update", UPDATE},
{"user", USER},
diff --git a/src/interfaces/ecpg/preproc/preproc.y b/src/interfaces/ecpg/preproc/preproc.y
index 5f67ff48d42..cc8528e4355 100644
--- a/src/interfaces/ecpg/preproc/preproc.y
+++ b/src/interfaces/ecpg/preproc/preproc.y
@@ -563,7 +563,7 @@ output_statement(char * stmt, int mode)
DATABASE, DELIMITERS, DO, EACH, EXPLAIN, EXTEND,
FORWARD, FUNCTION, HANDLER,
INCREMENT, INDEX, INHERITS, INSTEAD, ISNULL,
- LANCOMPILER, LISTEN, LOAD, LOCK_P, LOCATION, MAXVALUE, MINVALUE, MOVE,
+ LANCOMPILER, LISTEN, UNLISTEN, LOAD, LOCK_P, LOCATION, MAXVALUE, MINVALUE, MOVE,
NEW, NONE, NOTHING, NOTNULL, OIDS, OPERATOR, PROCEDURAL,
RECIPE, RENAME, RESET, RETURNS, ROW, RULE,
SEQUENCE, SETOF, SHOW, START, STATEMENT, STDIN, STDOUT, TRUSTED,
@@ -723,6 +723,7 @@ stmt: AddAttrStmt { output_statement($1, 0); }
| GrantStmt { output_statement($1, 0); }
| IndexStmt { output_statement($1, 0); }
| ListenStmt { output_statement($1, 0); }
+ | UnlistenStmt { output_statement($1, 0); }
| LockStmt { output_statement($1, 0); }
| ProcedureStmt { output_statement($1, 0); }
| RecipeStmt { output_statement($1, 0); }
@@ -2108,6 +2109,12 @@ ListenStmt: LISTEN relation_name
}
;
+UnlistenStmt: UNLISTEN relation_name
+ {
+ $$ = cat2_str(make1_str("unlisten"), $2);
+ }
+;
+
/*****************************************************************************
*
* Transactions: