1. 程式人生 > >navicat MySQL 語句

navicat MySQL 語句

1.使用navicat.exe視覺化工具管理資料庫

2.SELECT * FROM t_user WHERE uid =1;

SELECT uname FROM t_user;//顯示所有

SELECT DISTINCT uname FROM t_user;//如需從 uname " 列中僅選取唯一不同的值

SELECT * FROM t_user WHERE uid >2 AND uname ='hjj';

SELECT * FROM t_user WHERE uid >2 OR uname ='hjj';

SELECT * FROM t_user  ORDER BY uid DESC ;//uid按照降序

SELECT * FROM t_user  ORDER BY uid ;//預設升序

INSERT INTO t_user (uname) VALUES ('hjjhjh');

SELECT * from jibie LIMIT 1

UPDATE Person SET FirstName = 'Fred' WHERE LastName = 'Wilson' 

DELETE from t_user;