CREATE TABLE A(isDo char(10) PRIMARY KEY,isWrong char(8) NOT NULL,chose char(8),tiHao INTEGER )
create table temp as select * from A;
更新一列的多个数据
update tableA set isDo=(select isDo from tableB where tiHao=tableA.tiHao)
////改名
ALTER TABLE tableA RENAME TO tableB ;
删除
DROP TABLE tableA ;
插入
INSERT INTO tableA(key_id,key_name,key_age)VALUES(0 "name",90);
添加一列
alter table tableName add (columnName typeName);
例:alter table myTable add (myColumn varchar2(10))
select * from tableA e union select * from tableB
导入 数据并过滤
insert into tableA select distinct * from tableB
清除表tableA 数据
delete from tableA ;
/////test 附加 当前数据库 ATTACH DATABASE 'C:\Users\Administrator\Desktop\test.db' AS 'one'
原文链接:https://www.f2er.com/sqlite/199925.html