22
22
#include <drizzled/function/additive_op.h>
25
29
Set precision of results for additive operations (+ and -)
27
31
void Item_func_additive_op::result_precision()
31
35
args[1]->decimal_precision() - args[1]->decimals);
34
38
/* Integer operations keep unsigned_flag if one of arguments is unsigned */
35
39
if (result_type() == INT_RESULT)
36
40
unsigned_flag= args[0]->unsigned_flag | args[1]->unsigned_flag;
38
42
unsigned_flag= args[0]->unsigned_flag & args[1]->unsigned_flag;
39
44
max_length= my_decimal_precision_to_length(precision, decimals,