《数据库系统原理》课程设计报告
from Reader
create view Borrowview (读者编号,书名,作者,借阅日期,到期日期) as
select ReaID,BookName,BookWriter,Outdate,YHdate from Borrow,Book
where Borrow.BookID=Book.BookID and Borrow.Indate is null
create view Historyview (读者编号,书名,借阅日期,归还日期) as
select ReaID,BookName,Outdate,Indate from Borrow,Book
where Borrow.BookID=Book.BookID and Borrow.Indate is not null
create view Fineview (读者编号,书名,借阅日期,归还日期,罚款,处理状态) as
select ReaID,BookName,Outdate,Indate,Fine,CLState from Borrow,Book
where Borrow.BookID=Book.BookID and Fine is not null
create trigger Reader_delete on Reader for delete as
delete Borrow from deleted
where Borrow.ReaID=deleted.ReaID create trigger Borrow_insert1 on Borrow for insert as
declare @BookID char(9) select @BookID=BookID from inserted update Book
set BookState='不可借' where BookID=@BookID
37
《数据库系统原理》课程设计报告
课程设计评分表
评分标准: 1. 学生是否严格遵守课程设计纪律,按照规定时间完成设计任务(占30%) 2. 课程设计报告书质量:(占40%) (1)是否采用了良好的设计方法,独立完成课程设计。 (2)课程设计各分段的任务是否按时完成及完成的质量。 (3)是否完成课程设计任务书指定的全部要求。 3. 课程设计报告书的撰写规范 (占30%) 课程设计报告书的撰写规范要求与毕业设计(论文)的要求相同。 教师评分: 1. 学生出勤得分: _________ 2. 内容质量得分: _________ 3. 撰写规范得分: _________ 最终评定成绩(以优、良、中、及格、不及格评定):_________ 教师评语: 签字: 日期: 年 月 日
38