1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

Merge maint2.mysql.com:/data/localhome/tsmith/bk/41

into  maint2.mysql.com:/data/localhome/tsmith/bk/50
This commit is contained in:
tsmith@maint2.mysql.com
2006-09-01 08:53:56 +02:00
12 changed files with 147 additions and 46 deletions

View File

@ -2354,9 +2354,14 @@ print_table_data(MYSQL_RES *result)
(void) tee_fputs("|", PAGER);
for (uint off=0; (field = mysql_fetch_field(result)) ; off++)
{
tee_fprintf(PAGER, " %-*s |",(int) min(field->max_length,
uint name_length= (uint) strlen(field->name);
uint numcells= charset_info->cset->numcells(charset_info,
field->name,
field->name + name_length);
uint display_length= field->max_length + name_length - numcells;
tee_fprintf(PAGER, " %-*s |",(int) min(display_length,
MAX_COLUMN_LENGTH),
field->name);
field->name);
num_flag[off]= IS_NUM(field->type);
not_null_flag[off]= IS_NOT_NULL(field->flags);
}