sqlite

1.创建表
CREATE TABLE IF NOT EXISTS UserTable (username TEXT primary key,password TEXT,email TEXT);


2.插入一条数据
INSERT OR REPLACE INTO UserTable (username , password,email) VALUES (?,?,?);


3.更新一条数据
UPDATE UserTable set password = ‘123456‘  where username = ‘wxhl‘;


4.查询数据
SELECT username,password,email FROM UserTable where username = ‘wxhl‘


5.删除数据
DELETE FROM UserTable WHERE username=‘wxhl‘


6.模糊查询
SELECT *FROM UserTable Where username is LIKE "流%"


7.倒叙排列(默认正)
SELECT *FROM UserTable ORDER BY sage DESC


sqlite

上一篇:SqlCommandBuilder.DeriveParamters(SqlCommand)


下一篇:AT5759 ThREE(构造)