数据库上机考试、跪求大神 跪求答案、、

数据库上机考试、跪求大神 跪求答案、、,第1张

1select sno from spj where sno=j1;

2select sno from spj where sno=j1 and pno = p1;

3select sno from spj where sno = j1 and pno in ( select pno from p where color = red)

4select jno from spj where sno not in ( select sno from s where city = tianjin)

And pno not in ( select pno from p where color = red)

5select sname city from s

6select PNAME,COLOR,WEIGHT from p;

7select jno from spj where sno = s1;

8 select pname ,qty from spj as a ,p as b where apno = bpno and jno = j2

9 select pno from s , spj where sno = spjsno and city = shanghai;

10 select jno from s , spj where sno = spjsno and city = shanghai

11select jno from s , spj where sno = spjsno and city ! = tianjin

这个软件是否有什么配置连接数据库的地方?可能是连接数据库参数被改动了。或者数据库发什么了什么变化。使软件连接不上数据库。或者连接出错。这个光这样看是看不出什么问题的。 联系下这个软件公司的人处理下。 要不别人也不知道你这个是什么。

采纳哦

borrower:

create table borrower(

借书证号 char[5] primary key,

姓名 char[20] not null,

系名 char[10],

班级 char[10])

create table loans(

借书证号 char[5],

图书登记号 char[6],

结束日期 DATE,

primary key(借书证号,图书登记号),

foreign key(借书证号) reference borrower(借书证号),

foreign key(图书登记号 reference books(图书登记号))

create table books(

索书号 char[10],

书名 char[20],

图书登记号 char[6] primary key,

出版社 char[20],

价格 smallint))

(1)

select borrower借书证号,姓名,系名,temptotal as 借书数量

from borrower,(select 借书证号,count(图书登记号) as total

from loans group by 借书证号

where tatal>5 as temp(借书证号,total))

(2)

select borrower姓名,系名,书名,结束日期

from borrower,loans,books

where borrower借书证号=loans借书证号

and books图书登记号=loans图书登记号

and 书名 in(selcet 书名

from borrower,loans,books

where borrower借书证号=loans借书证号

and books图书登记号=loans图书登记号

and 姓名='赵垒')

(3)

create view SB

as

select borrower借书证号,姓名,班级,books图书登记号,书名,出版社

,借书日期

from borrower,book,loans

where borrower借书证号=loans借书证号

and books图书登记号=loans图书登记号

and 系名='信息系'

1

create table student(

sno char[10] primary key,

sname char[20] not null,

ssex char[2],

sage smallint check( sage between 16 and 30),

sdept char[4])

create table course(

cno char[10] primary key,

cname char[20] not null,

cteacher char[20])

create table sc(

sno char[10],

cno char[10],

grade smallint check(grade is null or grade between 0 and

100),

primary key(sno,cno)

foreign key sno reference student(sno),

foreign key cno reference course(cno))

2

insert into student values('102','李四','男',16,'数学')

下同

insert into course values('203',' *** 作系统','程羽')

下同

insert into sc values('101','203',82)

下同

3

(1) select cname,grade

from sc,student,course

where studentsno=scsno and coursecno=sccno

and sname='张三'

(2) select sname from student

where sno in(select sno from sc x

where not exists(

select from sc y

where xsno=ysno

and ygrade<60))

(3) select cname,sname,grade

from student,course sc,(select cno,max(grade) from sc group by cno

as temp(cno,max))

where studentsno=scsno and coursecno=sccno

and grade=max and coursecno=tempcno

4

delete from sc where grade<60

5

update sc

set grade=(select avg(grade) from sc where cno='203')

where sno=105

仅供参考

对啊

就是这样子的啊

我已经考过计算机网络三级了

*** 作过程也就那样啊

你还练习过,我直接就去上机考试了,也不知道如何 *** 作

监考老师在开考时会介绍的,

程序编写完后,要保存,然后运行一下看是否有误,如果出现问题了,还可以再修改的!!修改过后记得要保存再运行啊

不过你也不用太担心了,到时候会有老师给你们说的!!

以上就是关于数据库上机考试、跪求大神 跪求答案、、全部的内容,包括:数据库上机考试、跪求大神 跪求答案、、、安装上机系统总是出现"数据库连接错误,将退出系统",什么原因、跪解以下2道数据库系统原理上机试题等相关内容解答,如果想了解更多相关内容,可以关注我们,你们的支持是我们更新的动力!

欢迎分享,转载请注明来源:内存溢出

原文地址: http://outofmemory.cn/sjk/9481624.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2023-04-28
下一篇 2023-04-28

发表评论

登录后才能评论

评论列表(0条)

保存