sql server 2000 谁能帮我看2个小题

[复制链接]
查看11 | 回复2 | 2008-6-22 14:07:43 | 显示全部楼层 |阅读模式
41. 在SQLServer2000中,假设orders表中存在自动编号字段oid等于1的记录,执行下面T-SQL,以下说法正确的是()。 (选择一项)
BEGIN TRANSACTION
Delete from Orders where oid =1
IF(@@Error0)
ROLLBACK TRANSACTION
Else
COMMIT TRANSACTION
a) 执行成功,oid 为1的记录被永久删除
b) 执行成功,order表没有任何变化
c) 执行时出现错误
d) 执行成功,但事务处理并没有结束
24. 下列语句中书写正确的是()。 (选择一项)
a) select * from student where jiguan exists('湖北','上海','江苏')
b) select * from student where name in '邓巧' or '姚明' or '杜祥'
c) select * from student where sex = '女' and age > any(select age from student where name in('高强','草蜢','东方'+'神起'))
d) select * from student where sex = '男' and age > all(17,18,19)

回复

使用道具 举报

千问 | 2008-6-22 14:07:43 | 显示全部楼层
a) 执行成功,oid 为1的记录被永久删除 c) select * from student where sex = '女' and age > any(select age from student where name in('高强','草蜢','东方'+'神起'))
回复

使用道具 举报

千问 | 2008-6-22 14:07:43 | 显示全部楼层
c) 执行时出现错误 c) select * from student where sex = '女' and age > any(select age from student where name in('高强','草蜢','东方'+'神起'))
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行