SQL基本语句

增 删 改 查,数据库基本语句就是这4种,以下为举例

 

update 个人信息 set 出生日期='1980-7-6' where 姓名=‘张三’

更新   表名 把  出生日期改为1980年7月6号 条件是 姓名等于张三的


delete from 个人信息 where 姓名=‘张三’ and 性别=no

删除  从    表名 条件 姓名等于张三 并且性别等于no的


insert into 个人信息 (姓名,性别,出生日期,个人简历,身高)  vaules ('张三’,‘yes’,‘1980-3-3',‘shuoming',1.78)

增加        表名是个人信息  


select * from 个人信息 where 姓名<>'张三'

查找   全部   从    表名  条件是 姓名不等于张三


select 身高,出生日期 from 个人信息 where 姓名<>‘张三’

posted on 2014-01-06 11:42  shellcode  阅读(157)  评论(0编辑  收藏  举报

导航