提交 4260bd71 编写于 作者: S st0 提交者: LINGuanRen

support INTERVAL + expr

上级 fcc0cea1
......@@ -1278,6 +1278,15 @@ bit_expr '|' bit_expr %prec '|'
check_ret(setup_token_pos_info_and_dup_string($$, result, @1.first_column, @4.last_column),
&@1, result);
}
| INTERVAL expr date_unit '+' bit_expr
{
ParseNode *params = NULL;
malloc_non_terminal_node(params, result->malloc_pool_, T_EXPR_LIST, 3, $5, $2, $3);
make_name_node($$, result->malloc_pool_, "date_add");
malloc_non_terminal_node($$, result->malloc_pool_, T_FUN_SYS, 2, $$, params);
check_ret(setup_token_pos_info_and_dup_string($$, result, @1.first_column, @4.last_column),
&@1, result);
}
| bit_expr '-' INTERVAL expr date_unit %prec '-'
{
ParseNode *params = NULL;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册