DBZ-3017 Allow parentheses for functions with optional

This commit is contained in:
Jiri Pechanec 2021-02-03 07:46:58 +01:00 committed by Gunnar Morling
parent c33e46cffa
commit e526821594
2 changed files with 3 additions and 1 deletions

View File

@ -2220,7 +2220,7 @@ specificFunction
: (
CURRENT_DATE | CURRENT_TIME | CURRENT_TIMESTAMP
| CURRENT_USER | LOCALTIME | UTC_TIMESTAMP
) #simpleFunctionCall
) ('(' ')')? #simpleFunctionCall
| CONVERT '(' expression separator=',' convertedDataType ')' #dataTypeFunctionCall
| CONVERT '(' expression USING charsetName ')' #dataTypeFunctionCall
| CAST '(' expression AS convertedDataType ')' #dataTypeFunctionCall

View File

@ -42,3 +42,5 @@ SELECT 'Aleem' UNION ALL SELECT 'Latif' UNION ALL SELECT 'Mughal';
insert into t values ('кириллица', 2, 3);
insert INTO `wptests_posts` (`post_author`, `post_date`, `post_date_gmt`, `post_content`, `post_content_filtered`, `post_title`, `post_excerpt`, `post_status`, `post_type`, `comment_status`, `ping_status`, `post_password`, `post_name`, `to_ping`, `pinged`, `post_modified`, `post_modified_gmt`, `post_parent`, `menu_order`, `post_mime_type`, `guid`) VALUES (7, '2016-09-06 16:49:51', '2016-09-06 16:49:51', '', '', 'صورة', '', 'inherit', 'attachment', 'open', 'closed', '', '%d8%b5%d9%88%d8%b1%d8%a9', '', '', '2016-09-06 16:49:51', '2016-09-06 16:49:51', 0, 0, 'image/jpeg', '');
#end
insert into sql_log values(retGUID,log_type,log_text,0,0,current_user,now());
insert into sql_log values(retGUID,log_type,log_text,0,0,current_user(),now());