码迷,mamicode.com
首页 > 数据库 > 详细

sqlite3

时间:2016-03-11 20:21:20      阅读:210      评论:0      收藏:0      [点我收藏+]

标签:

 1.终端操作

技术分享

 

创建表

create table if not exists Student (id integer primary key autoincrement,name varchar[20] not null,address varchar[100],image blob);

查看自己的创建语句

技术分享

插入数据

insert into Student(name,address) values("huoran","ruanjianyuan");

查找

技术分享

 

select * from Student where id = 2;

select name from Student where id = 2;

更新

update Student set address = "nanjing" where name = "baoyun";

删除

delete from Student where id = 1;

删除表

drop table Student;

2.代码操作

 

sqlite3

标签:

原文地址:http://www.cnblogs.com/huoran1120/p/5266835.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!