use library;
######### Begin #########
# -- 27、 查询当前借书过期还没归还的用户的借阅证号、姓名、书名,并按借阅证号排序。
select Loan.loanNo as loanno, lname,bname
from Loan, Users,BookInfo,Books,Class_User
where Books.bookNo=Loan.bookNo and BookInfo.ISBN=Books.ISBN and Class_User.classNo=Users.ClassNo and
Loan.loanNo=Users.loanNo and datediff (now(),borrowDate)>term
order by bname desc;
######### End ##########
educoder第2关:任务2-CTGU实验2-查询27
最新推荐文章于 2024-08-29 17:00:41 发布