Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
postgres-lambda-diff
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Jakob Huber
postgres-lambda-diff
Commits
2a545255
Commit
2a545255
authored
21 years ago
by
Michael Meskes
Browse files
Options
Downloads
Patches
Plain Diff
- Allowed some C keywords to be used as SQL column names.
parent
a05977ed
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/interfaces/ecpg/ChangeLog
+1
-0
1 addition, 0 deletions
src/interfaces/ecpg/ChangeLog
src/interfaces/ecpg/preproc/preproc.y
+14
-2
14 additions, 2 deletions
src/interfaces/ecpg/preproc/preproc.y
with
15 additions
and
2 deletions
src/interfaces/ecpg/ChangeLog
+
1
−
0
View file @
2a545255
...
@@ -1739,5 +1739,6 @@ Mon Jan 26 21:57:14 CET 2004
...
@@ -1739,5 +1739,6 @@ Mon Jan 26 21:57:14 CET 2004
Sun Feb 15 14:44:14 CET 2004
Sun Feb 15 14:44:14 CET 2004
- Added missing braces to array parsing.
- Added missing braces to array parsing.
- Allowed some C keywords to be used as SQL column names.
- Set ecpg version to 3.1.1.
- Set ecpg version to 3.1.1.
This diff is collapsed.
Click to expand it.
src/interfaces/ecpg/preproc/preproc.y
+
14
−
2
View file @
2a545255
/* $PostgreSQL: pgsql/src/interfaces/ecpg/preproc/preproc.y,v 1.27
2
2004/02/15 1
3:48:54
meskes Exp $ */
/* $PostgreSQL: pgsql/src/interfaces/ecpg/preproc/preproc.y,v 1.27
3
2004/02/15 1
5:38:20
meskes Exp $ */
/* Copyright comment */
/* Copyright comment */
%{
%{
...
@@ -528,7 +528,7 @@ add_additional_variables(char *name, bool insert)
...
@@ -528,7 +528,7 @@ add_additional_variables(char *name, bool insert)
%type <str> user_name opt_user char_variable ora_user ident opt_reference
%type <str> user_name opt_user char_variable ora_user ident opt_reference
%type <str> var_type_declarations quoted_ident_stringvar ECPGKeywords_rest
%type <str> var_type_declarations quoted_ident_stringvar ECPGKeywords_rest
%type <str> db_prefix server opt_options opt_connection_name c_list
%type <str> db_prefix server opt_options opt_connection_name c_list
%type <str> ECPGSetConnection ECPGTypedef c_args ECPGKeywords
%type <str> ECPGSetConnection ECPGTypedef c_args ECPGKeywords
ECPGCKeywords
%type <str> enum_type civar civarind ECPGCursorStmt ECPGDeallocate
%type <str> enum_type civar civarind ECPGCursorStmt ECPGDeallocate
%type <str> ECPGFree ECPGDeclare ECPGVar opt_at enum_definition
%type <str> ECPGFree ECPGDeclare ECPGVar opt_at enum_definition
%type <str> struct_union_type s_struct_union vt_declarations execute_rest
%type <str> struct_union_type s_struct_union vt_declarations execute_rest
...
@@ -5747,6 +5747,7 @@ ColId: ident { $$ = $1; }
...
@@ -5747,6 +5747,7 @@ ColId: ident { $$ = $1; }
| unreserved_keyword { $$ = $1; }
| unreserved_keyword { $$ = $1; }
| col_name_keyword { $$ = $1; }
| col_name_keyword { $$ = $1; }
| ECPGKeywords { $$ = $1; }
| ECPGKeywords { $$ = $1; }
| ECPGCKeywords { $$ = $1; }
| CHAR_P { $$ = make_str("char"); }
| CHAR_P { $$ = make_str("char"); }
;
;
...
@@ -5756,6 +5757,7 @@ type_name: ident { $$ = $1; }
...
@@ -5756,6 +5757,7 @@ type_name: ident { $$ = $1; }
| unreserved_keyword { $$ = $1; }
| unreserved_keyword { $$ = $1; }
| ECPGKeywords { $$ = $1; }
| ECPGKeywords { $$ = $1; }
| ECPGTypeName { $$ = $1; }
| ECPGTypeName { $$ = $1; }
| ECPGCKeywords { $$ = $1; }
;
;
/* Function identifier --- names that can be function names.
/* Function identifier --- names that can be function names.
...
@@ -5764,6 +5766,7 @@ function_name: ident { $$ = $1; }
...
@@ -5764,6 +5766,7 @@ function_name: ident { $$ = $1; }
| unreserved_keyword { $$ = $1; }
| unreserved_keyword { $$ = $1; }
| func_name_keyword { $$ = $1; }
| func_name_keyword { $$ = $1; }
| ECPGKeywords { $$ = $1; }
| ECPGKeywords { $$ = $1; }
| ECPGCKeywords { $$ = $1; }
;
;
/* Column label --- allowed labels in "AS" clauses.
/* Column label --- allowed labels in "AS" clauses.
...
@@ -5775,6 +5778,7 @@ ColLabel: ECPGColLabel { $$ = $1; }
...
@@ -5775,6 +5778,7 @@ ColLabel: ECPGColLabel { $$ = $1; }
| INPUT_P { $$ = make_str("input"); }
| INPUT_P { $$ = make_str("input"); }
| INT_P { $$ = make_str("int"); }
| INT_P { $$ = make_str("int"); }
| UNION { $$ = make_str("union"); }
| UNION { $$ = make_str("union"); }
| ECPGCKeywords { $$ = $1; }
;
;
ECPGColLabelCommon: ident { $$ = $1; }
ECPGColLabelCommon: ident { $$ = $1; }
...
@@ -5789,6 +5793,14 @@ ECPGColLabel: ECPGColLabelCommon { $$ = $1; }
...
@@ -5789,6 +5793,14 @@ ECPGColLabel: ECPGColLabelCommon { $$ = $1; }
| ECPGKeywords_rest { $$ = $1; }
| ECPGKeywords_rest { $$ = $1; }
;
;
ECPGCKeywords: S_AUTO { $$ = make_str("auto"); }
| S_CONST { $$ = make_str("const"); }
| S_EXTERN { $$ = make_str("extern"); }
| S_REGISTER { $$ = make_str("register"); }
| S_STATIC { $$ = make_str("static"); }
| S_TYPEDEF { $$ = make_str("typedef"); }
;
/*
/*
* Keyword classification lists. Generally, every keyword present in
* Keyword classification lists. Generally, every keyword present in
* the Postgres grammar should appear in exactly one of these lists.
* the Postgres grammar should appear in exactly one of these lists.
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment