1
0
mirror of https://github.com/MariaDB/server.git synced 2025-12-24 11:21:21 +03:00

BUG#10466 Datatype "timestamp" displays "YYYYMMDDHHMMSS" irrespective of display sizes.

- Use buffer for printing error message 


sql/sql_parse.cc:
  Use buffer for string
This commit is contained in:
unknown
2005-06-20 12:11:52 +02:00
parent d2b52d1933
commit fc0c652c07

View File

@@ -5464,9 +5464,9 @@ bool add_field_to_list(THD *thd, char *field_name, enum_field_types type,
In other words, for declarations such as TIMESTAMP(2), TIMESTAMP(4),
and so on, the display width is ignored.
*/
String str;
str.append("TIMESTAMP");
str.append("(");
char buff[32];
String str(buff,(uint32) sizeof(buff), system_charset_info);
str.append("TIMESTAMP(");
str.append(length);
str.append(")");
push_warning_printf(thd,MYSQL_ERROR::WARN_LEVEL_WARN,