Select 22 DNO4 EMPLOYEE SALARY30000 EMPLOYEE DNO4 AND
- Slides: 58
실렉트(Select) 연산 (2/2) 관계 대수와 관계 해석 예제: • σDNO=4 (EMPLOYEE) • σSALARY>30000 (EMPLOYEE) • σ(DNO=4 AND SALARY>25000) OR DNO=5 (EMPLOYEE) Page 5 Database by Yang-Sae Moon
실렉트 연산의 실행 예제 관계 대수와 관계 해석 σ(DNO=4 AND SALARY>25000) OR (DNO=5 AND SALARY>30000) (EMPLOYEE) Page 6 Database by Yang-Sae Moon
실렉트 연산과 SQL 질의 관계 대수와 관계 해석 실렉트 연산 예제: σ DNO=4 AND SALARY>25000 (EMPLOYEE) 대응하는 SQL 질의 SELECT * FROM EMPLOYEE WHERE DNO=5 AND SALARY > 25000; Page 7 Database by Yang-Sae Moon
프로젝트 연산의 실행 예제 ΠFNAME, LNAME, SALARY(EMPLOYEE) Page 11 관계 대수와 관계 해석 ΠSEX, SALARY (EMPLOYEE) Database by Yang-Sae Moon
연산 순서와 이름 변경 연산 (5/5) 관계 대수와 관계 해석 SQL에서의 별명 사용으로 해석 가능함 • TEMP ←σDNO=5(EMPLOYEE) • R(FIRSTNAME, LASTNAME, SALARY) ← ΠFNAME, LNAME, SALARY(TEMP) SELECT E. FNAME AS FIRSTNAME, E. LNAME AS LASTNAME, E. SALARY AS SALARY FROM EMPLOYEE AS E WHERE E. DNO=5; Page 16 Database by Yang-Sae Moon
합집합, 교집합, 차집합 연산 (4/4) 관계 대수와 관계 해석 STUDENT ∪ INSTRUCTOR STUDENT ∩ INSTRUCTOR STUDENT - INSTRUCTOR - STUDENT Page 21 Database by Yang-Sae Moon
카티션 곱 (또는 크로스 프로덕트) 연산 (2/3) 관계 대수와 관계 해석 모든 여자사원들에 대해 그들의 부양가족들의 이름을 검색 • FENAME_EMPS ← σSEX=F(EMPLOYEE) • EMPNAMES ← ΠFNAME, LNAME, SSN(FENAME_EMPS) • EMP_DEPENDENTS ← EMPNAMES × DEPENDENT • ACTUAL_DEPENDENTS ← σSSN=ESSN(EMP_DEPENDENTS) • RESULT ← ΠFNAME, LNAME, DEPENDENT_NAME(ACTUAL_DEPENDENTS) Page 23 Database by Yang-Sae Moon
카티션 곱 (또는 크로스 프로덕트) 연산 (3/3) 관계 대수와 관계 해석 FENAME_EMPS ← σSEX=F(EMPLOYEE) EMPNAMES ← ΠFNAME, LNAME, SSN(FENAME_EMPS) EMP_DEPENDENTS ← EMPNAMES × DEPENDENT ACTUAL_DEPENDENTS ← σSSN=ESSN(EMP_DEPENDENTS) RESULT ← ΠFNAME, LNAME, DEPENDENT_NAME (ACTUAL_DEPENDENTS) 3 × 7 = 21 Page 24 Database by Yang-Sae Moon
조인(Join) 연산 (2/2) 관계 대수와 관계 해석 DEPT_MGR ← DEPARTMENT Page 27 MGRSSN=SSNEMPLOYEE Database by Yang-Sae Moon
동등 조인 (Equi-Join) 관계 대수와 관계 해석 조인 조건에서 동등 비교(equality comparison) 만을 사용하는 조인 EQUIJOIN 사용 예제: 모든 DEPARTMENT의 이름과 그 관리자의 이름을 검색하라: DEPT_MGR ← DEPARTMENT MGRSSN=SSN EMPLOYEE RESULT ← ΠDNAME, FNAME, LNAME(DEPT_MGR) Page 28 Database by Yang-Sae Moon
자연 조인(Natural Join) (2/4) 관계 대수와 관계 해석 DNUM DEPT DNUM PROJ_DEPT ← PROJECT DEPT DNUM Page 30 Database by Yang-Sae Moon
자연 조인(Natural Join) (3/4) 관계 대수와 관계 해석 DNUMBER DEPT_LOCS ← DEPT_LOCATIONS DEPARTMENT DNUMBER Page 31 Database by Yang-Sae Moon
디비전 연산 (2/3) 관계 대수와 관계 해석 = T←R S T 1 = ΠB(R) T 2 = ΠB((S × T 1) – R) T = T 1 – T 2 T 1 B b 1 b 2 b 3 b 4 a 1, a 2, a 3와의 모든 조합이 있는 놈: b 1, b 4 Page 37 S×T 1 A a 1 a 1 a 2 a 2 a 3 a 3 B b 1 b 2 b 3 b 4 S×T 1 - R A a 1 a 2 T 2 B b 2 b 3 T B b 1 b 4 B b 3 b 2 Database by Yang-Sae Moon
디비전 연산 (3/3) 관계 대수와 관계 해석 질의: Smith가 근무하는 모든 프로젝트에서 근무하는 사원들의 이름을 검색하라. = SMITH ← σFNAME=‘John’ AND LNAME=‘Smith’(EMPLOYEE) SMITH_PNOS ← ΠPNO(WORKS_ON ESSN=SSNSMITH) SSN_PNOS ← ΠESSN, PNO(WORKS_ON) SSNS(SSN) ← SSNPNOS SMITH_PNOS RESULT ← ΠFNAME, LNAME(SSNS * EMPLOYEE) Page 38 Database by Yang-Sae Moon
순환적 폐포(Recursive Closure) 연산 (2/2) Page 43 관계 대수와 관계 해석 Database by Yang-Sae Moon
외부 조인 연산 (4/4) 관계 대수와 관계 해석 null TEMP ← EMPLOYEE SSN=MGRSSNDEPARTMENT RESULT ← ΠFNAME, MINIT, LNAME, DNAME(TEMP) Page 47 null Database by Yang-Sae Moon
외부 합집합(Outer Union) 연산 (1/2) 관계 대수와 관계 해석 합집합 호환성이 없는 두 릴레이션을 합집합(union)하는데 사용됨 • 데이터베이스 구조와 제약조건의 정의 방식 예제 • STUDENT(Name, SSN, Department, Advisor)와 • FACULTY(Name, SSN, Department, Rank)의 outer union은 • RESULT(Name, SSN, Department, Advisor, Rank) 임 • RESULT 에서 STUDENT 투플은 Rank 속성의 값이 null이고, FACULTY 투플은 Advisor 속성의 값이 null임 Page 48 Database by Yang-Sae Moon
- Select * from select
- Nemuadmin
- Select * from select
- Select * from select
- Employee attitudes and employee performance
- He prepares all hot and cold dessert
- Select significant and relevant information
- Algorithms for select and join operations
- Select from where and
- Lab 3-9: testing mode: select and install memory
- Ethical discipline in the workplace
- Ethics and employee rights and discipline
- Sally wants to select an entire paragraph
- Statement select case termasuk struktur pemrograman ….
- Select case en visual basic ejemplos
- Case score
- How to select a ppm solution
- What is the
- Select ename min(sal) from emp
- Valid log manager
- Prime choice select
- Heap sort algoritmo
- Data dictionary dbms
- To drive straight forward you should look
- Select one of the contemporary economic issues
- Examples of select committees
- Avaya contact center select
- Carry select adder
- Accenture delivery suite policy
- Select * from emp;
- Php sql injection 방지 함수
- V-select 예제
- Turbines are power absorbing devices
- Spark create table as select
- Select distinct r.sid
- Mosfet package types
- Carry select adder verilog
- Which ado.net object contains select command property?
- Distinct order by
- Goodcents menu
- Select the correct fbd of particle a
- Sas outer union corr
- Down select process
- Choose the incorrect one
- Displaying data from multiple tables
- Soal d
- Chapter 5
- Select distinct sql
- Mssql 튜닝 가이드
- Shrpe ratio
- Sql queries
- Slice tool ps
- Python select case
- In unary relational operations the select
- Quickselect
- Select a title for your poster
- Select a title for your poster
- Point as a noun
- Select initcap(product_name) from product; the result is