【正文】
an, the starting point of the ancient Silk Road, a trade channel established more than 2,000 years ago linking China, Central Asia and Europe. 。s cooperation with Central Asian countries, a senior official said. Shaanxi Governor Lou Qinjian said the province is fresh, rich and unique, as it was when it anchored one end of the ancient Silk Road. It is the best option for acmodating industrial transfers from East China or the world at large, he said on Wednesday in Xi39。s business development. Rudy Buttignol, president of the public broadcasting pany in British Columbia, Canada, said his work requires frequent travel to Chengdu and the policy makes the trips easier. Data from the city39。s largest breeding and research center. Three days are long enough for foreign visitors to visit those iconic tourist spots, he noted. The city is home to the remains of the Jin s ha civilization that dates back more than 3,000 years as well as the Qing cheng Mountains and the Du jiang yan irrigation system. Qing cheng has long been recognized as the birthplace of Taoism, China39。s 72hour visafree policy has attracted wide attention from both Chinese and foreign experts and businessmen since it took effect on Sept 1 last Command1 year. The program permits citizens from 51 countries and regions including the United States, Australia, Canada and Japan who have valid visas and flight tickets to a third country to spend three days in the ci ty. The capital of Sichuan province is the first city in the western region of China to offer foreign tourists a threeday visa and the fourth nationwide to adopt the policy following Shanghai, Beijing and Guangzhou. Li Zhiyong, deputy dean of the tourism institute at Sichuan University, said the move contributes to a large increase in the number of overseas tourists and raises the city39。請補充完成下列程序代碼。 參考答案 SELECT , FROM T, C, TC WHERE = AND = AND =’張紅 ’ 4.程序應(yīng)用題 設(shè)學(xué)生成績表的結(jié)構(gòu)為(學(xué)號、課程號、成績),程序運行界面如圖 1所示。 注意:說明主鍵碼和外鍵碼約束 參考答案及評分要點: 參考答案 CREATE TABLE TC{ TNo INT, CNo INT, PRIMARY KEY (Tno,Cno), FOREIGN KEY (TNo) REFERENCES T(TNo), FOREIGN KEY (CNo) REFERENCES C(CNo) }。 參考答案及評分要點: 參考答案 CREATE TABLE T{ TNo INT PRIMARY KEY, TN CHAR(30), TD CHAR(20), RANK CHAR(20) }。 圖 2“增加記錄”窗體運行界面 Private Sub Command1_Click() ‘聲明一個記錄集對象 Dim ADOrs As New Recordset ‘將記錄集對象與已建立的數(shù)據(jù)庫聯(lián)接對象 ADO綁定 =ADO ‘第一步:在課程表 Courses中查詢是否存在關(guān)鍵字相同的記錄 ( 1)拼寫查詢字符串 strSQL=“ Select CNo From courses Where Cno=‘” + Text1 + “’” ( 2)執(zhí)行查詢語句 strSQL ‘第二步:如果記錄已經(jīng)存在,則退出程序 If Not Then MsgBox “記錄已存在,不能繼續(xù)增加” Exit Sub End If ‘第三步:將結(jié)果插入到課程表 Courses中 ( 1)拼寫 Insert插入語句 strSQL = ( 2)執(zhí)行 Insert插入語句 Command1 strSQL End Sub 參考答案及評分要點: ‘第一步:在課程表 Courses中查詢是否存在關(guān)鍵字相同的記錄 strSQL=“ Select CNo From courses Where Cno=‘” + Text1 + “’” StrSQL (本小點 4分) ‘第二步:如果記錄已經(jīng)存在,則退出程序 If Not Then (本小點 6分) MsgBox “記錄已存在,不能繼續(xù)增加 ” Exit Sub End If ‘第三步:將結(jié)果插入到課程表 Courses中 strSQL = “ Insert Into courses(Cno,CName) Values(‘” +Text1+“’ ,‘” +Text2+“’ )” (本小點 6分) strSQL (本小點 4分) End Sub 1.用 SQL語句創(chuàng)建簡單數(shù)據(jù)表 設(shè)有兩個關(guān)系( 1)教師關(guān)系 T,包括教師編號 TNo,姓名 TN,系別 TD,職稱 RANK;( 2)課程關(guān)系 C,包括課程號 CNo,課程名 CN。進入界面后,用戶輸入所有數(shù)據(jù)后,點擊“確認(rèn)”按鈕后,將結(jié)果插入到課程表 Courses中。JK00139。 某教師希望查詢課程號為“ JK001”的課程的所有學(xué)生成績,并按如圖 1所示的方式顯示查詢結(jié)果,請寫出對應(yīng)的 Select查詢語句。 參考答案及評分要點: 參考答案 CREATE TABLE Courses( CNo CHAR(10) PRIMARY KEY, CName CHAR(10), ) 。 CNo和 CName均為字符型(長度 10)。請補充完成下列程序代碼。 3.程序應(yīng)用題 設(shè)學(xué)生成績表的結(jié)構(gòu)為(學(xué)號、課程號、成績),程序運行界面如圖 1所示。該數(shù)據(jù)表與物資臺賬數(shù)據(jù)表 T之間存在外鍵約束,即物資臺賬數(shù)據(jù)表 T中不存在的記錄不能夠出現(xiàn)在該表中。 Cn為數(shù)值型(兩位小數(shù))。 CREATE TABLE T ( TNo CHAR(20) PRIMARY KEY, TN CHAR(20), TD Money )。 五、綜合應(yīng)用題(第 2題每題 10分,第 3題 20分,共 40分) 1.用 SQL語句創(chuàng)建簡單數(shù)據(jù)表 設(shè)有物資臺賬數(shù)據(jù)表 T,包括物資編號 TNo,物資姓名 TN,單價 TD等字段; TNo和 TN為字符型(長度 20), TD 為數(shù)值型(帶小數(shù))。我們可以從以下兩方面理解函數(shù)依賴的概念:首先,對于該關(guān)系中每個職工的職工號,都對應(yīng)著姓名屬性中的惟一值,即該職工的姓名,或者說一個職工的姓名由其職工號惟一確定,所以稱職工號函數(shù)決定姓名,或稱姓名函數(shù)依賴于職工號( 1分)。若對于 X上的每個值都有 Y上的一個惟一值與之對應(yīng),則稱 X和 Y具有函數(shù)依賴關(guān)系,并稱 X函數(shù)決定 Y,或稱