下載本文檔
版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進(jìn)行舉報或認(rèn)領(lǐng)
文檔簡介
1、精選優(yōu)質(zhì)文檔-傾情為你奉上1. Consider the following three database schemas: Employee (person_name, street, city) Work (person_name, company_name, salary) Company (company_name, city)1) please write the queries in relational algebra(關(guān)系代數(shù)) according to the description:a. find out the name of all employees in city
2、cq;b. Find out the name and salary of all employees in corporation A;c. Find out the name and city of all employees in corporation B;2) Optimize the relational algebra expression C in 1), draw the optimized relational algebra expression tree.2. Consider the following three database schemas: Customer
3、s (cust_id, cust_name, cust_address,cust_phone ) Products (prod_id, prod_name, prod_type, prod_price, prod_number) Orders (order_id, cust_id, prod_id, number)1) Please write the following queries in SQL:a. Find out the name of products whose price is higher than ¥100.b. Find out the order numbe
4、r of customer Tom.2) Create a view to complete the following function: statistics the quantity of each type (prod type) inventory(庫存) Products.3) Create a product table which defines the primary key, and make sure that Prod_type must be one of “television”, ”refrigerator” and ”washing machine”.3. De
5、sign an E/R diagram for Bar. Both red wine and beer are supplied in Bar. Customers drink in the Bar. And the translate the E/R mode into relational model. Bar has name and address ,customers has name and birthday and all wines have manufacturer and brand.4. The functional dependency set F from relat
6、ion R(A,B,C,D,E,F) is shown as follows: F = A->E, B->D, CE->F, F->BCCalculate the closure(閉包) for attribute set AF.5. A B+ tree structure is shown in Fogure 1. G J E J K G E A B Figure 11) Write the modes from querying path between the root and the key value ”K”;2) Draw B+ tree after ins
7、ert key value “H” based on Figure 1;3) Draw B+ tree after insert key value “D” based on Figure 1.6. Describe explicitly the ACID properties of Transactions.7. You can select one of the following questions to answer.1) Set fire transactions, T1, T2, T3, T4, T5 whose timestamps are 1, 2, 3, 4, 5 respe
8、ctively .Fill in the blank of table 1 according to Timestamp-Based Protocols. “abort” is filled when operation is rejected. (Initial R-timestamp and W-timestamp is set too) Table 1A partial scheduleR-timestamp,W-timestamp Or abort T1 T2 T3 T4 T5 Read(y)R-timestamp(y)=1 Write(y)W-timestamp(y)=2 Read(
9、y)(_) Write(z)W-timestamp(z)=4 Read(x)R-timestamp(x)=1 Read(z)(_) Write(z)(_)Read(z)(_) Write(x)(_)2) Please answer the following query two question:(1) Consider the following query on the relation R(A, B, C, D)SELECT FROM RGROUP BY A, B Assume A, B, C, D take integer values Which can appear in the position marked as in following . MIN(C +
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負(fù)責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時也不承擔(dān)用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- 2025-2030年中國偶氮二異丁腈市場運行動態(tài)及投資發(fā)展前景調(diào)研報告
- 2025-2030年中國三氯乙烯行業(yè)市場發(fā)展前景調(diào)研及投資戰(zhàn)略分析報告
- 2025-2030年中國LED景觀照明行業(yè)全景調(diào)研及投資策略分析報告
- 2025-2030年中國3丁烯1醇行業(yè)十三五規(guī)劃與發(fā)展策略研究報告
- 福建省寧德市福鼎第九中學(xué)2021-2022學(xué)年高三數(shù)學(xué)文上學(xué)期期末試題含解析
- 福建省寧德市福安民族職業(yè)中學(xué)高三數(shù)學(xué)理模擬試題含解析
- 2024版智能車輛識別一體機銷售合同
- 2024年高校校園改造工程合同
- 2024年隧道工程資料收集與保管合同
- 福建省寧德市第一中學(xué)2021年高一物理下學(xué)期期末試題含解析
- 高三課題研究報告范文
- 2024年初三數(shù)學(xué)競賽考試試題
- 竇性心動過速的危害
- 深基坑工程基坑土方開挖及支護降水施工方案
- 2024年江西生物科技職業(yè)學(xué)院單招職業(yè)技能測試題庫帶解析答案
- 醫(yī)藥制造企業(yè)資本結(jié)構(gòu)優(yōu)化研究以貴州百靈為例
- GB 31335-2024鐵礦開采和選礦單位產(chǎn)品能源消耗限額
- 醫(yī)院高風(fēng)險意外事件應(yīng)急措施和救護機制
- 橋本甲狀腺炎-90天治療方案
- 【復(fù)合附件版】個人借車免責(zé)協(xié)議書簡單
- 焊接工裝夾具設(shè)計手冊
評論
0/150
提交評論