Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
3c634602
Commit
3c634602
authored
Oct 29, 2016
by
Aleksey Midenkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Parser: SYSTEM_TIME_SYM (fixes #67)
parent
7d815be1
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
5 deletions
+10
-5
sql/gen_lex_token.cc
sql/gen_lex_token.cc
+2
-0
sql/sql_lex.cc
sql/sql_lex.cc
+2
-0
sql/sql_yacc.yy
sql/sql_yacc.yy
+6
-5
No files found.
sql/gen_lex_token.cc
View file @
3c634602
...
...
@@ -132,6 +132,8 @@ void compute_tokens()
set_token
(
WITH_CUBE_SYM
,
"WITH CUBE"
);
set_token
(
WITH_ROLLUP_SYM
,
"WITH ROLLUP"
);
set_token
(
WITH_SYSTEM_SYM
,
"WITH SYSTEM"
);
set_token
(
FOR_SYSTEM_TIME_SYM
,
"FOR SYSTEM_TIME"
);
set_token
(
NOT2_SYM
,
"!"
);
set_token
(
OR2_SYM
,
"|"
);
set_token
(
PARAM_MARKER
,
"?"
);
...
...
sql/sql_lex.cc
View file @
3c634602
...
...
@@ -1333,6 +1333,8 @@ int MYSQLlex(YYSTYPE *yylval, THD *thd)
return
WITH_CUBE_SYM
;
case
ROLLUP_SYM
:
return
WITH_ROLLUP_SYM
;
case
SYSTEM
:
return
WITH_SYSTEM_SYM
;
default:
/*
Save the token following 'WITH'
...
...
sql/sql_yacc.yy
View file @
3c634602
...
...
@@ -859,10 +859,10 @@ bool my_yyoverflow(short **a, YYSTYPE **b, ulong *yystacksize);
%parse-param { THD *thd }
%lex-param { THD *thd }
/*
Currently there are 10
6
shift/reduce conflicts.
Currently there are 10
3
shift/reduce conflicts.
We should not introduce new conflicts any more.
*/
%expect 10
6
%expect 10
3
/*
Comments for TOKENS.
...
...
@@ -1093,7 +1093,7 @@ bool my_yyoverflow(short **a, YYSTYPE **b, ulong *yystacksize);
%token FORCE_SYM
%token FOREIGN /* SQL-2003-R */
%token FOR_SYM /* SQL-2003-R */
%token FOR_SYSTEM_TIME_SYM /*
internal
*/
%token FOR_SYSTEM_TIME_SYM /*
INTERNAL
*/
%token FORMAT_SYM
%token FOUND_SYM /* SQL-2003-R */
%token FROM
...
...
@@ -1575,6 +1575,7 @@ bool my_yyoverflow(short **a, YYSTYPE **b, ulong *yystacksize);
%token WITHOUT /* SQL-2003-R */
%token WITH_CUBE_SYM /* INTERNAL */
%token WITH_ROLLUP_SYM /* INTERNAL */
%token WITH_SYSTEM_SYM /* INTERNAL */
%token WORK_SYM /* SQL-2003-N */
%token WRAPPER_SYM
%token WRITE_SYM /* SQL-2003-N */
...
...
@@ -5849,7 +5850,7 @@ create_table_option:
Lex->create_info.used_fields|= HA_CREATE_USED_SEQUENCE;
Lex->create_info.sequence= $3;
}
| WITH
SYSTE
M VERSIONING
| WITH
_SYSTEM_SY
M VERSIONING
{
Vers_parse_info &info= Lex->vers_get_info();
info.declared_system_versioning= true;
...
...
@@ -6666,7 +6667,7 @@ serial_attribute:
new (thd->mem_root)
engine_option_value($1, &Lex->last_field->option_list, &Lex->option_list_last);
}
| WITH
SYSTE
M VERSIONING
| WITH
_SYSTEM_SY
M VERSIONING
{
Lex->last_field->versioning = Column_definition::WITH_VERSIONING;
Lex->create_info.vers_info.has_versioned_fields= true;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment