呵呵.
这些注释是不写到服务器的数据字典里的.
create table test1 ( id int auto_increment not null primary key , #this is id
topic char(50) not null default '', # this is topic
category char(50) not null default '',
re char(250) not null default '',
isvalid enum('Y','N') not null default 'Y',
time datetime not null default '1900-01-01'
)
COMMENT = "这里注释"
这些注释是不写到服务器的数据字典里的.
create table test1 ( id int auto_increment not null primary key , #this is id
topic char(50) not null default '', # this is topic
category char(50) not null default '',
re char(250) not null default '',
isvalid enum('Y','N') not null default 'Y',
time datetime not null default '1900-01-01'
)
COMMENT = "这里注释"
topic char(50) not null default '', add the COMMENT ' this is topic '
category char(50) not null default '',
re char(250) not null default '',
isvalid enum('Y','N') not null default 'Y',
time datetime not null default '1900-01-01'
)我同事告诉我用mysqlshow -i -u root -pXXX dbName test1是可以取到的,但是我在程序中用不了mysqlshow啊~~~怎么办??帮帮我啊~~~
topic char(50) not null default '', COMMENT ' this is topic '
category char(50) not null default '',
re char(250) not null default '',
isvalid enum('Y','N') not null default 'Y',
time datetime not null default '1900-01-01'
)
create table test1 (
id int auto_increment not null primary key COMMENT 'this is id'
)这个语句只在 MySQL 4.1 以及更新的版本中能正确使用.要得到注释信息
你可以在 程序里执行 SHOW CREATE TABLE `test1` 或者 SHOW FULL COLUMNS