diff options
author | Tor Lillqvist <tml@collabora.com> | 2018-01-02 18:46:33 +0200 |
---|---|---|
committer | Tor Lillqvist <tml@collabora.com> | 2018-01-02 20:09:35 +0100 |
commit | 72ff62a13af402d19e6e53b809b29033a985c04a (patch) | |
tree | 0ca4ab471d18c7c321d014378c964556ea34fbe8 /connectivity | |
parent | e0a22d47d281f61f51ead6d2831cd53c15036ffe (diff) |
tdf#104986: Add MILLISECOND, WEEKDAY, and YEARDAY tokens for Firebird
Change-Id: I2ba866c408dbf49f1655cc08cc5d0df840eaf01e
Reviewed-on: https://gerrit.libreoffice.org/47271
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tor Lillqvist <tml@collabora.com>
Diffstat (limited to 'connectivity')
-rw-r--r-- | connectivity/source/parse/sqlbison.y | 4 | ||||
-rw-r--r-- | connectivity/source/parse/sqlflex.l | 3 |
2 files changed, 5 insertions, 2 deletions
diff --git a/connectivity/source/parse/sqlbison.y b/connectivity/source/parse/sqlbison.y index 2c55bae0f66b..0f21bcc6fcc9 100644 --- a/connectivity/source/parse/sqlbison.y +++ b/connectivity/source/parse/sqlbison.y @@ -146,8 +146,8 @@ using namespace connectivity; /* time and date functions */ %token <pParseNode> SQL_TOKEN_CURRENT_DATE SQL_TOKEN_CURRENT_TIME SQL_TOKEN_CURRENT_TIMESTAMP SQL_TOKEN_CURDATE SQL_TOKEN_CURTIME %token <pParseNode> SQL_TOKEN_DAYNAME SQL_TOKEN_DAYOFMONTH SQL_TOKEN_DAYOFWEEK SQL_TOKEN_DAYOFYEAR SQL_TOKEN_EXTRACT -%token <pParseNode> SQL_TOKEN_HOUR SQL_TOKEN_MINUTE SQL_TOKEN_MONTH SQL_TOKEN_MONTHNAME SQL_TOKEN_NOW SQL_TOKEN_QUARTER SQL_TOKEN_DATEDIFF -%token <pParseNode> SQL_TOKEN_SECOND SQL_TOKEN_TIMESTAMPADD SQL_TOKEN_TIMESTAMPDIFF SQL_TOKEN_TIMEVALUE SQL_TOKEN_WEEK SQL_TOKEN_YEAR +%token <pParseNode> SQL_TOKEN_HOUR SQL_TOKEN_MILLISECOND SQL_TOKEN_MINUTE SQL_TOKEN_MONTH SQL_TOKEN_MONTHNAME SQL_TOKEN_NOW SQL_TOKEN_QUARTER SQL_TOKEN_DATEDIFF +%token <pParseNode> SQL_TOKEN_SECOND SQL_TOKEN_TIMESTAMPADD SQL_TOKEN_TIMESTAMPDIFF SQL_TOKEN_TIMEVALUE SQL_TOKEN_WEEK SQL_TOKEN_WEEKDAY SQL_TOKEN_YEAR SQL_TOKEN_YEARDAY /* numeric functions */ %token <pParseNode> SQL_TOKEN_ABS SQL_TOKEN_ACOS SQL_TOKEN_ASIN SQL_TOKEN_ATAN SQL_TOKEN_ATAN2 SQL_TOKEN_CEILING diff --git a/connectivity/source/parse/sqlflex.l b/connectivity/source/parse/sqlflex.l index 9d9f119fd640..5d8a59c27844 100644 --- a/connectivity/source/parse/sqlflex.l +++ b/connectivity/source/parse/sqlflex.l @@ -260,6 +260,7 @@ LOWER {SQL_NEW_KEYWORD(SQL_TOKEN_LOWER); } LTRIM {SQL_NEW_KEYWORD(SQL_TOKEN_LTRIM); } MAX {SQL_NEW_KEYWORD(SQL_TOKEN_MAX); } +MILLISECOND {SQL_NEW_KEYWORD(SQL_TOKEN_MILLISECOND); } MIN {SQL_NEW_KEYWORD(SQL_TOKEN_MIN); } MINUTE {SQL_NEW_KEYWORD(SQL_TOKEN_MINUTE); } MOD {SQL_NEW_KEYWORD(SQL_TOKEN_MOD); } @@ -394,6 +395,7 @@ VALUES {SQL_NEW_KEYWORD(SQL_TOKEN_VALUES); } VIEW {SQL_NEW_KEYWORD(SQL_TOKEN_VIEW); } WEEK {SQL_NEW_KEYWORD(SQL_TOKEN_WEEK); } +WEEKDAY {SQL_NEW_KEYWORD(SQL_TOKEN_WEEKDAY); } WHEN {SQL_NEW_KEYWORD(SQL_TOKEN_WHEN); } WHERE {SQL_NEW_KEYWORD(SQL_TOKEN_WHERE); } WITH {SQL_NEW_KEYWORD(SQL_TOKEN_WITH); } @@ -402,6 +404,7 @@ WITHOUT {SQL_NEW_KEYWORD(SQL_TOKEN_WITHOUT); } WORK {SQL_NEW_KEYWORD(SQL_TOKEN_WORK); } YEAR {SQL_NEW_KEYWORD(SQL_TOKEN_YEAR); } +YEARDAY {SQL_NEW_KEYWORD(SQL_TOKEN_YEARDAY); } ZONE {SQL_NEW_KEYWORD(SQL_TOKEN_ZONE); } |