ALTER TABLE table_name ALTER COLUMN column_name SET DEFAULT new_default
修改数据类型,使用命令:
ALTER TABLE table_name ALTER COLUMN column_name TYPE new_type
注意:这不会影响任何表中已经存在的行。
MYSQL m_sqlCon//声明mysql_init(&m_sqlCon)//初始化
mysql_real_connect(&m_sqlCon, "127.0.0.1", abc, "root", "hibernate", atoi("3306"),NULL,0)//链接
mysql_query(&m_sqlCon, "SET NAMES GB2312")//设置查询编码格式
res = mysql_query(&m_sqlCon,"select * from ms_sendlist where flag = 1 order by style desc")//查询
mysql_query(&m_sqlCon, sql)//插入,删除
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)