aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMarc G. Fournier <scrappy@hub.org>1999-02-04 04:58:05 +0000
committerMarc G. Fournier <scrappy@hub.org>1999-02-04 04:58:05 +0000
commitfc590b6f1a16302c66e160a5f840520534400fdb (patch)
tree86c291fb6815b2d2f1bc36a36b6260288272ffa1 /src
parenta03b81737311f0c7cb1e7617795c12c20cdafa58 (diff)
downloadpostgresql-fc590b6f1a16302c66e160a5f840520534400fdb.tar.gz
postgresql-fc590b6f1a16302c66e160a5f840520534400fdb.zip
From: Michael Meskes <Michael.Meskes@usa.net>
+ Tue Feb 2 07:40:52 CET 1999 + + - Brought preproc.y in sync again with gram.y. + - Set ecpg version to 2.4.9 +
Diffstat (limited to 'src')
-rw-r--r--src/interfaces/ecpg/ChangeLog5
-rw-r--r--src/interfaces/ecpg/preproc/Makefile2
-rw-r--r--src/interfaces/ecpg/preproc/keywords.c3
-rw-r--r--src/interfaces/ecpg/preproc/preproc.y18
4 files changed, 19 insertions, 9 deletions
diff --git a/src/interfaces/ecpg/ChangeLog b/src/interfaces/ecpg/ChangeLog
index 9e4389dac27..52a01f8e9ba 100644
--- a/src/interfaces/ecpg/ChangeLog
+++ b/src/interfaces/ecpg/ChangeLog
@@ -395,3 +395,8 @@ Fri Jan 29 18:03:52 CET 1999
- Fixed bug that caused function names to be translated to lower case.
- Set ecpg version to 2.4.8
+Tue Feb 2 07:40:52 CET 1999
+
+ - Brought preproc.y in sync again with gram.y.
+ - Set ecpg version to 2.4.9
+
diff --git a/src/interfaces/ecpg/preproc/Makefile b/src/interfaces/ecpg/preproc/Makefile
index 7d13a7a98ad..7fd98c8f06b 100644
--- a/src/interfaces/ecpg/preproc/Makefile
+++ b/src/interfaces/ecpg/preproc/Makefile
@@ -3,7 +3,7 @@ include $(SRCDIR)/Makefile.global
MAJOR_VERSION=2
MINOR_VERSION=4
-PATCHLEVEL=8
+PATCHLEVEL=9
CFLAGS+=-I../include -DMAJOR_VERSION=$(MAJOR_VERSION) \
-DMINOR_VERSION=$(MINOR_VERSION) -DPATCHLEVEL=$(PATCHLEVEL) \
diff --git a/src/interfaces/ecpg/preproc/keywords.c b/src/interfaces/ecpg/preproc/keywords.c
index 49f936aa8f9..787d60122a8 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.8 1999/01/18 17:17:01 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/interfaces/ecpg/preproc/keywords.c,v 1.9 1999/02/04 04:58:04 scrappy Exp $
*
*-------------------------------------------------------------------------
*/
@@ -212,6 +212,7 @@ static ScanKeyword ScanKeywords[] = {
{"stdout", STDOUT},
{"substring", SUBSTRING},
{"table", TABLE},
+ {"temp", TEMP},
{"then", THEN},
{"time", TIME},
{"timestamp", TIMESTAMP},
diff --git a/src/interfaces/ecpg/preproc/preproc.y b/src/interfaces/ecpg/preproc/preproc.y
index cda77f5281c..355bf31dda0 100644
--- a/src/interfaces/ecpg/preproc/preproc.y
+++ b/src/interfaces/ecpg/preproc/preproc.y
@@ -554,7 +554,7 @@ output_statement(char * stmt, int mode)
PARTIAL, POSITION, PRECISION, PRIMARY, PRIOR, PRIVILEGES, PROCEDURE, PUBLIC,
READ, REFERENCES, RELATIVE, REVOKE, RIGHT, ROLLBACK,
SCROLL, SECOND_P, SELECT, SET, SUBSTRING,
- TABLE, THEN, TIME, TIMESTAMP, TIMEZONE_HOUR, TIMEZONE_MINUTE,
+ TABLE, TEMP, THEN, TIME, TIMESTAMP, TIMEZONE_HOUR, TIMEZONE_MINUTE,
TO, TRAILING, TRANSACTION, TRIM, TRUE_P,
UNION, UNIQUE, UPDATE, USER, USING,
VALUES, VARCHAR, VARYING, VIEW,
@@ -637,7 +637,7 @@ output_statement(char * stmt, int mode)
%type <str> opt_decimal Character character opt_varying opt_charset
%type <str> opt_collate Datetime datetime opt_timezone opt_interval
%type <str> numeric a_expr_or_null row_expr row_descriptor row_list
-%type <str> SelectStmt SubSelect result
+%type <str> SelectStmt SubSelect result OptTemp
%type <str> opt_table opt_union opt_unique sort_clause sortby_list
%type <str> sortby OptUseOp opt_inh_star relation_name_list name_list
%type <str> group_clause having_clause from_clause c_list
@@ -1095,13 +1095,17 @@ copy_delimiter: USING DELIMITERS Sconst { $$ = cat2_str(make1_str("using delim
*
*****************************************************************************/
-CreateStmt: CREATE TABLE relation_name '(' OptTableElementList ')'
+CreateStmt: CREATE OptTemp TABLE relation_name '(' OptTableElementList ')'
OptInherit
{
- $$ = cat4_str(make1_str("create table"), $3, make3_str(make1_str("("), $5, make1_str(")")), $7);
+ $$ = cat5_str(make1_str("create"), $2, make1_str("table"), make3_str(make1_str("("), $6, make1_str(")")), $8);
}
;
+OptTemp: TEMP { $$ = make1_str("temp"); }
+ | /* EMPTY */ { $$ = make1_str(""); }
+ ;
+
OptTableElementList: OptTableElementList ',' OptTableElement
{
$$ = cat3_str($1, make1_str(","), $3);
@@ -1461,9 +1465,9 @@ OptInherit: INHERITS '(' relation_name_list ')' { $$ = make3_str(make1_str("inh
| /*EMPTY*/ { $$ = make1_str(""); }
;
-CreateAsStmt: CREATE TABLE relation_name OptCreateAs AS SubSelect
+CreateAsStmt: CREATE OptTemp TABLE relation_name OptCreateAs AS SubSelect
{
- $$ = cat5_str(make1_str("create table"), $3, $4, make1_str("as"), $6);
+ $$ = cat5_str(cat3_str(make1_str("create"), $2, make1_str("table")), $4, $5, make1_str("as"), $7);
}
;
@@ -2691,7 +2695,7 @@ SubSelect: SELECT opt_unique res_target_list2
}
;
-result: INTO opt_table relation_name { $$= cat3_str(make1_str("into"), $2, $3); }
+result: INTO OptTemp opt_table relation_name { $$= cat4_str(make1_str("into"), $2, $3, $4); }
| INTO into_list { $$ = make1_str(""); }
| /*EMPTY*/ { $$ = make1_str(""); }
;