freepeople性欧美熟妇, 色戒完整版无删减158分钟hd, 无码精品国产vα在线观看DVD, 丰满少妇伦精品无码专区在线观看,艾栗栗与纹身男宾馆3p50分钟,国产AV片在线观看,黑人与美女高潮,18岁女RAPPERDISSSUBS,国产手机在机看影片

正文內(nèi)容

[計算機軟件及應(yīng)用]第2章2關(guān)系數(shù)據(jù)庫-資料下載頁

2025-10-07 23:18本頁面
  

【正文】 結(jié)果: An Introduction to Database System 結(jié)果: π SNO,CNO(SC)247。 C Sno 1 An Introduction to Database System 舉例 :請注意下面查詢的區(qū)別 π SNO,CNO(SC)247。 C SC247。 C An Introduction to Database System 查詢選修了 2號同學(xué)選修的全部課程學(xué)生學(xué)號 Sno Cno Gra 1 A 80 2 B 90 3 C 88 1 B 70 1 C 67 Sno Cno Gra 2 B 90 SC SC Sno 1 2 An Introduction to Database System 分析以下表達(dá)式 SC 247。 σSNO =‘2’ ( SC) SC 247。 π CNO (σSNO =‘2’ ( SC) ) π SNO,CNO(SC)247。 π CNO (σSNO =‘2’ ( SC) ) An Introduction to Database System 5.綜合舉例 以學(xué)生 課程數(shù)據(jù)庫為例 (P60) [例 7] 查詢選修 1號課程和 3號課程的學(xué)生號碼 (SC)247。 σCno=‘1’∨ Cno=‘3’(C) An Introduction to Database System 綜合舉例 (續(xù) ) [例 8] 查詢選修了 2號課程的學(xué)生的學(xué)號 。 πSno( σCno=39。239。( SC)) An Introduction to Database System 綜合舉例 (續(xù) ) [例 9] 查詢至少選修了一門其直接先行課為 5號課程的課程的學(xué)生姓名 。 πSname(σCpno=39。539。(Course SC Student)) 或 πSname(σCpno=39。539。(Course) SC πSno, Sname(Student)) 或 πSname (πSno (σCpno=39。539。 (Course) SC) πSno, Sname (Student)) An Introduction to Database System 綜合舉例 (續(xù) ) [例 10] 查詢選修了全部課程的學(xué)生學(xué)號和姓名 。 (πSno, Cno( SC) 247。 πCno(Course)) πSno, Sname(Student) πSno, Sname ((πSno, Cno( SC) 247。 Course) (Student)) An Introduction to Database System 小結(jié) l 關(guān)系代數(shù)運算 ? 關(guān)系代數(shù)運算 并 、 差 、 交 、 笛卡爾積 、 投影 、 選擇 、 連接 、 除 ? 基本運算 并 、 差 、 笛卡爾積 、 投影 、 選擇 ? 交 、 連接 、 除 可以用 5種基本運算來表達(dá) 引進(jìn)它們并不增加語言的能力 , 但可以簡化表達(dá) An Introduction to Database System ? R∩ S = R –(RS) ? R S =σ AθB(R S) ? R(X,Y)247。 S(Y,Z)= πX(R)πX(πX(R) πY(S)R) AθB An Introduction to Database System 作業(yè) P74 第五題 An Introduction to Database System 第二章 關(guān)系數(shù)據(jù)庫 關(guān)系模型概述 關(guān)系數(shù)據(jù)結(jié)構(gòu) 關(guān)系的完整性 關(guān)系代數(shù) 關(guān)系演算 小結(jié) An Introduction to Database System 關(guān)系演算 ? 關(guān)系演算 以數(shù)理 邏輯 中的謂詞演算為基礎(chǔ) ? 種類:按謂詞變元不同分類 : 以 元組變量 作為謂詞變元的基本對象 元組關(guān)系演算語言 ALPHA : 以 域變量 作為謂詞變元的基本對象 域關(guān)系演算語言 QBE An Introduction to Database System 關(guān) 系 演 算 ? 元組關(guān)系演算 An Introduction to Database System 元組關(guān)系演算 ? 元組關(guān)系演算系統(tǒng)中,稱 {t | Φ(t)} 為元組演算表達(dá)式。其中 t是元組變量, Φ(t)簡稱公式。 該元組演算表達(dá)式表示了使 Φ(t)為真的元組集合。 An Introduction to Database System 原子公式的基本類型 ? 原子公式 1. R(t) 表示 t是關(guān)系 R的元組 2. t[i]θu[j] t[i]和 u[j]表示分量, θ比較符, i、 j是整數(shù) 3. t[i]θc 或者 cθt[i] c是常量 An Introduction to Database System 公式遞歸定義 ? 每個原子公式是公式 ? 如果 Φ1和 Φ2是公式, 那么 Φ1∧ Φ2, Φ1∨ Φ2, ﹁ Φ1也是公式。 ? 如果 Φ是公式,那么 ?t(Φ)也是公式。 若有一個 t使 Φ為真,則 ?t(Φ)為真,否則為假。 ? 如果 Φ是公式,那么 t(Φ)也是公式。 對所有的 t使 Φ為真, 則該為真,否則為假。 ?An Introduction to Database System ? 關(guān)系代數(shù)的運算均可以用關(guān)系演算表達(dá)式表示,下面用關(guān)系演算表達(dá)式來表示五種基本運算: An Introduction to Database System (1) 并 R∪ S = { t|R(t)∨ S(t) } (2) 差 RS = { t|R(t)∧ ?S(t) } (3) 笛卡爾積 R S = {t(n+m)|(?u(n)) (?v(m))(R(u)∧ S(v)∧ t[1]=u[1]∧ … ∧ t[n]=u[n] ∧ t[n+1]=v[1]∧ … ∧ t[n+m]=v[m] } An Introduction to Database System (4) 投影 Πi1,i2, …ik(R) = {t(k)|(?u)(R(u)∧ t[1]=u[i1]∧ … ∧ t[k]=u[ik] )} (5) 選擇 σF(R) = {t|R(t)∧ F39。} F39。與 F是等價公式 An Introduction to Database System 用關(guān)系演算表示查詢 ? [例 1]查詢信息系( IS系)全體學(xué)生 {t|student (t)∧ t[5]=‘IS’} ? [例 2]查詢年齡小于 20歲的學(xué)生 {t|student (t)∧ t[4]20} An Introduction to Database System ? [例 3]查詢學(xué)生姓名和所在的系 {t(2)|(?u) (student(u)∧ t[1]=u[2]∧ t[2]=u[5]}
點擊復(fù)制文檔內(nèi)容
教學(xué)課件相關(guān)推薦
文庫吧 www.dybbs8.com
備案圖鄂ICP備17016276號-1