summaryrefslogtreecommitdiff
path: root/sql/item_row.cc
diff options
context:
space:
mode:
authormonty@mysql.com <>2005-04-01 15:04:50 +0300
committermonty@mysql.com <>2005-04-01 15:04:50 +0300
commit201ee3eb78da55c72c627c6aa09a51899e31c4a7 (patch)
tree7920c948db7d0f2174fb24ba26cd648144fa4850 /sql/item_row.cc
parente9205dc0f0f6e5dcc184a9e71fb85e9eec51a8a8 (diff)
downloadmariadb-git-201ee3eb78da55c72c627c6aa09a51899e31c4a7.tar.gz
Invalid DEFAULT values for CREATE TABLE now generates errors. (Bug #5902)
CAST() now produces warnings when casting a wrong INTEGER or CHAR values. This also applies to implicite string to number casts. (Bug #5912) ALTER TABLE now fails in STRICT mode if it generates warnings. Inserting a zero date in a DATE, DATETIME or TIMESTAMP column during TRADITIONAL mode now produces an error. (Bug #5933)
Diffstat (limited to 'sql/item_row.cc')
-rw-r--r--sql/item_row.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/sql/item_row.cc b/sql/item_row.cc
index 00d849e55de..0c8baa332ca 100644
--- a/sql/item_row.cc
+++ b/sql/item_row.cc
@@ -73,8 +73,8 @@ bool Item_row::fix_fields(THD *thd, TABLE_LIST *tabl, Item **ref)
with_null|= item->null_inside();
else
{
- item->val_int();
- with_null|= item->null_value;
+ if (item->is_null())
+ with_null|= 1;
}
}
maybe_null|= item->maybe_null;