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

Merge neptunus.(none):/home/msvensson/mysql/mysql-5.0

into neptunus.(none):/home/msvensson/mysql/bug10466
This commit is contained in:
msvensson@neptunus.(none)
2005-06-27 13:12:10 +02:00
31 changed files with 66 additions and 41 deletions

View File

@@ -5493,6 +5493,23 @@ bool add_field_to_list(THD *thd, char *field_name, enum_field_types type,
DBUG_RETURN(1);
}
if (type == FIELD_TYPE_TIMESTAMP && length)
{
/* Display widths are no longer supported for TIMSTAMP as of MySQL 4.1.
In other words, for declarations such as TIMESTAMP(2), TIMESTAMP(4),
and so on, the display width is ignored.
*/
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,
ER_WARN_DEPRECATED_SYNTAX,
ER(ER_WARN_DEPRECATED_SYNTAX),
str.c_ptr(), "TIMESTAMP");
}
if (!(new_field= new_create_field(thd, field_name, type, length, decimals,
type_modifier, default_value, on_update_value,
comment, change, interval_list, cs, uint_geom_type)))