summaryrefslogtreecommitdiff
path: root/sql/item_create.cc
diff options
context:
space:
mode:
Diffstat (limited to 'sql/item_create.cc')
-rw-r--r--sql/item_create.cc5
1 files changed, 1 insertions, 4 deletions
diff --git a/sql/item_create.cc b/sql/item_create.cc
index 962ea73f320..4bd3d4f7e47 100644
--- a/sql/item_create.cc
+++ b/sql/item_create.cc
@@ -5815,10 +5815,7 @@ Item *create_temporal_literal(THD *thd,
MYSQL_TIME_STATUS status;
MYSQL_TIME ltime;
Item *item= NULL;
- ulonglong flags= thd->variables.sql_mode &
- (MODE_NO_ZERO_IN_DATE |
- MODE_NO_ZERO_DATE |
- MODE_INVALID_DATES);
+ ulonglong flags= sql_mode_for_dates(thd);
switch(type)
{