教学文库网 - 权威文档分享云平台
您的当前位置:首页 > 范文大全 > 资料大全 >

高级sql_4上机答案

来源:网络收集 时间:2026-09-08
导读: 1. use studentDB update students set sex='女' select*from students where age(select age from students where sname='张三') 2. use studentDB select sname from students where sno in(select sno from scores where lno='01') 3. use studentDB sele

1.
use studentDB
update students set sex='女'
select*from students where age>(select age from students where sname='张三')
2.
use studentDB
select sname from students where sno in(select sno from scores where lno='01')
3.
use studentDB
select sname from students where sno in (select sno from scores)
4.
update students set age=age+1
where sno not in (select sno from scores)
5.
select lname from lessons where lno not in (select lno from scores)
6.
if (exists (select * from scores where score>80))
update scores set score=score+2
else
update scores set score=score+1
7.
if (not exists (select * from scores where score>60))
update scores set score=score+3
else
update scores set score=score+1
8.
if ( exists (select * from scores where score>60))
update scores set score=score+0
else
update scores set score=score+2



1.
use libraryDB
select bname from books where pubdate>(select pubdate from books where bno='001')
2.
select rname,department from readers where rno in(select rno from borrows where bno='001')
3.
select
bname from books where bno not in (select bno from borrows)
4.
select rname from readers where rno not in(select rno from borrows)
5.

高级sql_4上机答案.doc 将本文的Word文档下载到电脑,方便复制、编辑、收藏和打印
本文链接:https://www.jiaowen.net/fanwen/2192185.html(转载请注明文章来源)
Copyright © 2020-2025 教文网 版权所有
声明 :本网站尊重并保护知识产权,根据《信息网络传播权保护条例》,如果我们转载的作品侵犯了您的权利,请在一个月内通知我们,我们会及时删除。
客服QQ:78024566 邮箱:78024566@qq.com
苏ICP备19068818号-2
Top
× 游客快捷下载通道(下载后可以自由复制和排版)
VIP包月下载
特价:29 元/月 原价:99元
低至 0.3 元/份 每月下载150
全站内容免费自由复制
VIP包月下载
特价:29 元/月 原价:99元
低至 0.3 元/份 每月下载150
全站内容免费自由复制
注:下载文档有可能出现无法下载或内容有问题,请联系客服协助您处理。
× 常见问题(客服时间:周一到周五 9:30-18:00)