sqlserver 大杂烩

Sql语句:

查询:select * from student where studentID=5 

增加:insert into student (name,age,class) values(rows,20,软件工程)

删除:delete from student where studentID=5

修改:update student set class=网络工程 where studentID=5

 

存储过程:

create procedure goods_info as

  select * from googs g inner  jion googs_class gc on g.name=gc.name.

 

连接:

inner outer join(内连接)   :  结果集合中包含符合条件的行  。

left outer join (左外连接) :结果集合中不仅包含符合条件的行,还包含左表中的不满足条件的数据行。null

right outer join(右外连接) :  结果集合中不仅包含符合条件的行,还包含右表中的不满足条件的数据行。  null

right outer join (全外连接):  结果集合中不仅包含符合条件的行,还包含2个中的不满足条件的数据行。null

 

不满足条件的行,列值为null。

posted @ 2011-02-27 21:58  JackGIS  阅读(157)  评论(0编辑  收藏  举报