SqlLite (无类型)

DDL (CREATE, DELETE)
CREATE TABLE IF NOT EXITS t_student (name text, age integer);
CREATE TABLE IF NOT EXITS t_teacher (name, age);

DROP TABLE IF EXITS t_student;

DML
INSERT INTO t_student (name, age) VALUES ('jinming', 24);
UPDATE t_student SET name = 'jindong', age = 23 WHERE price < 1000;
DELETE FROM t_student ;

DQL
SELECT * FROM t_student ORDER by name DESC, age ASC;

外键: 一张表的某个字段引用着另外一张表的主键 (一对多, 外键加在夺得那端)

你可能感兴趣的:(SqlLite (无类型))