Description:
I start with the following two statements
set @arg00= 8 ;
create table tx as select @arg00 as a1 ;
MySQL delivers on 'show create table tx'
Table Create Table
tx CREATE TABLE `tx` (`a1` bigint(8192) default NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1
This CREATE TABLE statement is not correct, because
'CREATE TABLE `tx_dupl` ( `a1` bigint(8192) default NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1 '
gives error 1074: Column length too big for column 'a1' (max = 255); use BLOB instead
BTW: - CREATE TABLE tx_dupl LIKE tx works successful
- I am able to perform DML statements on the table tx.
- The error message contains a useless hint, because a BLOB is a non numeric type.
My environment: Intel PC with Linux(SuSE 9.0)
MySQL 4.1 source distrib. (last bk pull 2004-07-28)
How to repeat:
please use the statements above
Suggested fix:
What about bigint instead of the incorrect bigint(8192) ?
The MySQL manual says in chapter "12 Column Types":
...
Several of the column type descriptions use these conventions:
M Indicates the maximum display size. The maximum legal display size is 255.
Description: I start with the following two statements set @arg00= 8 ; create table tx as select @arg00 as a1 ; MySQL delivers on 'show create table tx' Table Create Table tx CREATE TABLE `tx` (`a1` bigint(8192) default NULL ) ENGINE=MyISAM DEFAULT CHARSET=latin1 This CREATE TABLE statement is not correct, because 'CREATE TABLE `tx_dupl` ( `a1` bigint(8192) default NULL ) ENGINE=MyISAM DEFAULT CHARSET=latin1 ' gives error 1074: Column length too big for column 'a1' (max = 255); use BLOB instead BTW: - CREATE TABLE tx_dupl LIKE tx works successful - I am able to perform DML statements on the table tx. - The error message contains a useless hint, because a BLOB is a non numeric type. My environment: Intel PC with Linux(SuSE 9.0) MySQL 4.1 source distrib. (last bk pull 2004-07-28) How to repeat: please use the statements above Suggested fix: What about bigint instead of the incorrect bigint(8192) ? The MySQL manual says in chapter "12 Column Types": ... Several of the column type descriptions use these conventions: M Indicates the maximum display size. The maximum legal display size is 255.