auto merge 5.0-bugteam --> 5.1-bugteam (bug 40761)

This commit is contained in:
Gleb Shchepa 2008-12-12 18:19:33 +04:00
commit cd42f4ba2c
3 changed files with 27 additions and 1 deletions

View file

@ -362,7 +362,10 @@ public:
Item_func_unsigned(Item *a) :Item_func_signed(a) {}
const char *func_name() const { return "cast_as_unsigned"; }
void fix_length_and_dec()
{ max_length=args[0]->max_length; unsigned_flag=1; }
{
max_length= min(args[0]->max_length, DECIMAL_MAX_PRECISION + 2);
unsigned_flag=1;
}
longlong val_int();
virtual void print(String *str, enum_query_type query_type);
};