1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-01 03:47:19 +03:00

Bug #53814: NUMERIC_PRECISION for unsigned bigint field is 19,

should be 20

Fixed the numeric precision of the unsigned BIGINT column to 
be 20 instead of 19.
This commit is contained in:
Georgi Kodinov
2010-06-23 19:25:31 +03:00
parent 0860015560
commit c38864d426
3 changed files with 37 additions and 1 deletions

View File

@ -3965,10 +3965,13 @@ static int get_schema_column_record(THD *thd, TABLE_LIST *tables,
case MYSQL_TYPE_TINY:
case MYSQL_TYPE_SHORT:
case MYSQL_TYPE_LONG:
case MYSQL_TYPE_LONGLONG:
case MYSQL_TYPE_INT24:
field_length= field->max_display_length() - 1;
break;
case MYSQL_TYPE_LONGLONG:
field_length= field->max_display_length() -
((field->flags & UNSIGNED_FLAG) ? 0 : 1);
break;
case MYSQL_TYPE_BIT:
field_length= field->max_display_length();
decimals= -1; // return NULL