【单选题】统计图书信息表中每个出版社图书的平均价格。能得到正确结果的SELECT语句是 A: A、select pubname,AVG(price) from bookinfo order by puname B: select pubname,AVG(price) from bookinfo group by pubname C: select pubname,price from bookinfo D: select pubname,AVG(price) from bookinfo
【单选题】统计图书信息表中每个出版社图书的平均价格。能得到正确结果的SELECT语句是 A: A、select pubname,AVG(price) from bookinfo order by puname B: select pubname,AVG(price) from bookinfo group by pubname C: select pubname,price from bookinfo D: select pubname,AVG(price) from bookinfo
【单选题】显示图书信息表中不同书架图书的平均价格大于50元的书架号和平均价格。能得到正确结果的SELECT语句是 A: select casename,AVG(price) <br> from bookinfo group by casename where AVG(price)>50 B: select casename,AVG(price)>50 from bookinfo group by casename C: select casename,AVG(price) <br> from bookinfo<br> having AVG(price)>50 group by casename D: select casename,AVG(price) <br> from bookinfo group by casename<br> having AVG(price)>50
【单选题】显示图书信息表中不同书架图书的平均价格大于50元的书架号和平均价格。能得到正确结果的SELECT语句是 A: select casename,AVG(price) <br> from bookinfo group by casename where AVG(price)>50 B: select casename,AVG(price)>50 from bookinfo group by casename C: select casename,AVG(price) <br> from bookinfo<br> having AVG(price)>50 group by casename D: select casename,AVG(price) <br> from bookinfo group by casename<br> having AVG(price)>50
创建存储过程prcgetprice,通过输入图书编号,使用输出参数返回图书价格,根据题目完成以下代码的填空。create proc prcgetprice@BookID varchar(50),@Price float OUTPUT asbegin try if exists(select * from BookInfo where BookID=@BookID) begin declare @Price float SET @Price=0 select @Price =Price from BookInfo where BookID=@BookIDend trybegin catch print 'error'end catch执行prcgetprice存储过程查询图书编号为B001图书的价格,填充语句。declare @Price floatexec prcgetprice 'B001',@Price ___print @Price
创建存储过程prcgetprice,通过输入图书编号,使用输出参数返回图书价格,根据题目完成以下代码的填空。create proc prcgetprice@BookID varchar(50),@Price float OUTPUT asbegin try if exists(select * from BookInfo where BookID=@BookID) begin declare @Price float SET @Price=0 select @Price =Price from BookInfo where BookID=@BookIDend trybegin catch print 'error'end catch执行prcgetprice存储过程查询图书编号为B001图书的价格,填充语句。declare @Price floatexec prcgetprice 'B001',@Price ___print @Price
智慧职教: 创建触发器TR_LEND2,当LendInfo(借阅表)中有数据添加时,能自动更新StudentInfo(读者表)中该读者的借阅数量(LendBooks)及BookInfo(图书信息表)中该图书的在库数量(RemainNum)。请选择适当的语句填空。CREATE TRIGGER TR_LEND2ON LendInfoFOR INSERTAS
智慧职教: 创建触发器TR_LEND2,当LendInfo(借阅表)中有数据添加时,能自动更新StudentInfo(读者表)中该读者的借阅数量(LendBooks)及BookInfo(图书信息表)中该图书的在库数量(RemainNum)。请选择适当的语句填空。CREATE TRIGGER TR_LEND2ON LendInfoFOR INSERTAS