Loading mysql-test/r/func_misc.result +6 −0 Original line number Diff line number Diff line Loading @@ -195,9 +195,15 @@ NULL SELECT NAME_CONST('test', 1); test 1 SELECT NAME_CONST('test', -1); test -1 SELECT NAME_CONST('test', 1.0); test 1.0 SELECT NAME_CONST('test', -1.0); test -1.0 SELECT NAME_CONST('test', 'test'); test test Loading mysql-test/t/func_misc.test +2 −0 Original line number Diff line number Diff line Loading @@ -199,7 +199,9 @@ SELECT NAME_CONST('test', UPPER('test')); SELECT NAME_CONST('test', NULL); SELECT NAME_CONST('test', 1); SELECT NAME_CONST('test', -1); SELECT NAME_CONST('test', 1.0); SELECT NAME_CONST('test', -1.0); SELECT NAME_CONST('test', 'test'); --echo End of 5.0 tests Loading sql/item_func.h +1 −0 Original line number Diff line number Diff line Loading @@ -435,6 +435,7 @@ class Item_func_neg :public Item_func_num1 longlong int_op(); my_decimal *decimal_op(my_decimal *); const char *func_name() const { return "-"; } virtual bool basic_const_item() const { return args[0]->basic_const_item(); } void fix_length_and_dec(); void fix_num_length_and_dec(); uint decimal_precision() const { return args[0]->decimal_precision(); } Loading Loading
mysql-test/r/func_misc.result +6 −0 Original line number Diff line number Diff line Loading @@ -195,9 +195,15 @@ NULL SELECT NAME_CONST('test', 1); test 1 SELECT NAME_CONST('test', -1); test -1 SELECT NAME_CONST('test', 1.0); test 1.0 SELECT NAME_CONST('test', -1.0); test -1.0 SELECT NAME_CONST('test', 'test'); test test Loading
mysql-test/t/func_misc.test +2 −0 Original line number Diff line number Diff line Loading @@ -199,7 +199,9 @@ SELECT NAME_CONST('test', UPPER('test')); SELECT NAME_CONST('test', NULL); SELECT NAME_CONST('test', 1); SELECT NAME_CONST('test', -1); SELECT NAME_CONST('test', 1.0); SELECT NAME_CONST('test', -1.0); SELECT NAME_CONST('test', 'test'); --echo End of 5.0 tests Loading
sql/item_func.h +1 −0 Original line number Diff line number Diff line Loading @@ -435,6 +435,7 @@ class Item_func_neg :public Item_func_num1 longlong int_op(); my_decimal *decimal_op(my_decimal *); const char *func_name() const { return "-"; } virtual bool basic_const_item() const { return args[0]->basic_const_item(); } void fix_length_and_dec(); void fix_num_length_and_dec(); uint decimal_precision() const { return args[0]->decimal_precision(); } Loading