【正文】
Is_loandates1 and =0。 if Il_b =0 then messagebox(信息錯(cuò)誤 ,此圖書編號(hào)的書未被借出! ) return end if if Il_jIs_loandates1 and Il_jIl_k then insert into momey values(:Is_bookid, :Il_e , :Il_m )。 delete from momey where =:Is_bookid 。 select count(*) into:Il_a from loan where =1。 用戶手冊(cè) 說明 借書:當(dāng)借一本書時(shí)將此的在 bookinfo 表中的標(biāo)記 flag1 置為 1,其他人再借此書時(shí)先判斷 flag1 是否為 1,如果為 1 則不可再借此書。并判斷是否超期以及計(jì)算超期天數(shù)和罰款金額,并將其輸入 money 表中,當(dāng)顯示其記錄以后將 money 表中的信息刪除。按照書上介紹的數(shù)據(jù)庫(kù)設(shè)計(jì)的步驟,我首先進(jìn)行需求分析,得到了圖書管理員詳細(xì)的回答后,我想的是這些細(xì)節(jié)的東西應(yīng)該應(yīng)用到我們具體哪些步驟中。再以后 SQL 建表時(shí)也不確定。在此謝謝老師和同學(xué)的幫忙,順利完成了我大 學(xué)的第一個(gè)課程設(shè)計(jì)。 通過這次的數(shù)據(jù)庫(kù)課程設(shè)計(jì),開始對(duì)數(shù)據(jù)庫(kù)的應(yīng)用有了初步的了解,知道了怎么通過編程建立一個(gè)具有一定功能的系統(tǒng)。在畫數(shù)據(jù)流程圖和完成數(shù)據(jù)字典的時(shí)候,其實(shí)遇到很多困難,主要集中在數(shù)據(jù)字典中,數(shù)據(jù)項(xiàng)的填寫很亂,我們覺得我們完成的結(jié)果中應(yīng)該存在很多問題。 總結(jié) 這次的課程設(shè)計(jì)是我進(jìn)入大學(xué)接觸的第一個(gè) 有關(guān)于數(shù)據(jù)庫(kù)的 課程設(shè)計(jì),好多東西都不會(huì)。同時(shí)還需要判斷證件是否被掛失,所借的書是否有超期的。這時(shí)應(yīng)按原設(shè)計(jì)要求重新安排存儲(chǔ)位置、回收垃圾、減少指針鏈等,提高系統(tǒng)性能。 if Il_a=1 then messageBox(提示信息 ,圖書編號(hào)為 +string(long(Is_bookid))+的圖書已還借成功 ) end if = () 查看圖書借閱記錄: string Is_title integer Il_b Is_title=trim() if not = then (Is_title ) else messageBox(數(shù)據(jù)不全 ,請(qǐng)輸入書名 ) return end if select count(*) into:Il_b from loan,bookinfo where = and =:Is_title。 end if (Is_bookid) update bookinfo set flag1=0 where =:Is_bookid。 Il_e=abs(DaysAfter(date(datetime(Il_d)),date(datetime(Is_loandates1)))30) Il_m=double(Il_e*) if Il_jIs_loandates1 and Il_jIl_k then messagebox(提示信息 ,所借書在 +string(datetime(Il_j))+ 已超期,罰款+string(double(Il_m))+元,請(qǐng)交罰款! ) end if select into:Il_w from loan where =:Is_bookid 。 if Il_b=0 then messagebox(信息錯(cuò)誤 ,此證件無(wú)借書信息! ) return end if select into:Il_v from loan where =:Is_cert_id and =:Is_flag。//借書后將本書的 flag1 置 1 = = () 查看借書記錄: long Is_cert_id,Il_d,Il_a,Il_b,Il_v datetime Is_loandates,Is_returndates,Il_j,Il_k integer Is_flag,Il_f Is_loandates=datetime(today()) Is_cert_id=long() //Is_returndates=relativedate(today(),30) select into:Il_j from loan where =:Is_cert_id and :Is_loandates and =0。 if Il_b=1 then messagebox(信息錯(cuò)誤 ,此書已被借出! ) return end if insert into loan values(:Is_bookid, :Is_cert_id, :Is_loandates, :Is_returndates, :Is_flag)。 messagebox(信息錯(cuò)誤 ,所借書已超 6 本,請(qǐng)先還書! ) () return end if select into:Il_m from bookinfo where =:Is_bookid。 if Il_jIs_loandates and Il_jIl_k then messagebox(提示信息 ,所借書在 +string(datetime(Il_j))+ 已超期,請(qǐng)你還書! ) () return end if select into:Il_a from CertificateInfo where =:Is_cert_id。 DBMS 產(chǎn)品一般都提供了一些系統(tǒng)配置變量、存儲(chǔ)分配參數(shù),根據(jù)應(yīng)用環(huán)境確 定這些參數(shù)值,并且在系統(tǒng)運(yùn)行時(shí)還要根據(jù)系統(tǒng)實(shí)際運(yùn)行情況進(jìn)行調(diào)整,以使系統(tǒng)性能最佳。 11.查詢,刪除,包括讀者借書證編號(hào)、讀者姓名、書籍編號(hào)、書籍名稱等 ( 3) 關(guān)系模式: (一 ) 管理員(賬號(hào),密碼) (二 ) 讀者(借書證編號(hào),讀者姓名,專業(yè),班級(jí),借書數(shù)目) (三 ) 書籍(書籍編號(hào),書籍名稱,著者,出版社名稱,標(biāo)注) (四 ) 借閱( 借書證編號(hào), 書籍編號(hào),書名,讀者借書時(shí)間) (五 ) 還書( 借書證編號(hào), 書籍編號(hào),書名,讀者還書時(shí)間) (注:關(guān)系模式四和五,在數(shù)據(jù)表設(shè)計(jì)中將合并成一張表實(shí)