您的位置:首页 > 数据库 > MySQL

MySQL Conclusion

2013-10-31 11:08 281 查看
1、Select total count from a table:

select count(1) from 'tablename' where 1=1 ;

2、No where condition delete whole table data method:

SET SQL_SAFE_UPDATES=0 ;

3、How to connect String?

in MySQL: use concat(string1,string2);[/code]

4、How to Unique constraint on multiple fields?

alter table Variable_Entries add unique (var_id, value);


5、How to import sql-script to EER-diagram in mysql workbench?

in EER-Diagram perspective, select FILE-->import-->Reverse Engineer MySQL Create Script, OK!
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: