Title: Databases:
1???? ???????????
- Databases
- An Introduction
2??? ??? ???????
- ??? ?????? ??? ???? ?? ?????? ?????? ????? ???
????? ??????? ????? ?????? ???? ??????, ???????? - Database Management System (DBMS)
- ???? ????? ??? ????? ??? ??? ?? ???? ???? ?????
????? ?????? - ???? ????? ???? ???? ????????
3??? ????????
- ?????? ?????? ???? ???? ???? ??????? ??????
???????? - ??? ?????? ?????? ????? ??????? ??????? ??????
??????? ?????? ??????? ???? ?????? ???? ??????
????? ??????? ?? ?????? - ?? ?? ????? ??????? ?????? ?????? ?-PC ????
?????????? ?? ???? ??????, ???? ????? ??????
(spreadsheets)
4???????
- ?.?.?., ????? ????? ?????? ???????, ????? ????
??????? ??????? - ??????? ??????? ??? (????? ?????, ????? ???') ???
?????? ???? ??????? ????? ????? ???? ?????? ????
????? ?????? ????? ?????, ????? ?????? ?.?.?.
?????? ????? ??????
5??? ?? ?????
- ???? ???? ??? ???? ????? (????? ????? ???????)
??? ???? ??????, ???? ????? ?? ???? ????? - ????? ????? ???? ???? ?????? ?????? ??? ?????
????? ?? ??????? ?????? ??????? ????? ?? ?.?.?.
(?? ?? ??? ????? ???? ?? ??????? ????? ?????? ?"?
??????)
6??? DBMS?????? ?????? ???? ??????
- ????? ????? ?????? ???? ???? ?????? ????? (??????
?????????), ??????? - ?????? ????? ??? ?? ????? ?? ???????
- ???? ???? ??? ?????? ???????? ?? ?? ???????
- ???? ???? ??? ??????? ???????? ???????
- ????? ?????? ????? ?"? ??? ???????
- ??? ??, ?????? ???? ?????? ?????? ??????
7??? DBMS? (????)???? ?????? ???????
- ???? ?????? ??-????? (??????)
- ????? ?????? ????? ?"? ???? ????? ????? ????
- ????? ?????? ????? ?? ?????
- ????? ?? ????? ??????? (data integrity)
- ?? ????? ???? ???? ?"? ??? ????? ?????
- ?? ???? ???? ??? ?????? ?????
- ??? ?????? ??? ?????
- ????? ?? ?????? ??????? (security) ?"? ??? ??????
??????? (authorization)
8???? ???????
- ???? ??????? ??? ???? ?? ?????? ???????? ??? ????
????? ?????? ?? ??????? ??? ??????? (???,
???????? ?? ???????) - ??????? ??? ???? ??????? ???? ??????? ????
- ???? ????? ?? ???? ???????
- ????? ????? ????? ??? ????? ????? (????? ????????
?? Relational Model)
9???? ?????
- ????? ?????? ????? ?? ?????? ????? ?? ???????
- ???? ???????
- ????? ??????? ?? ?????
- ????????
- ????, ??? ?? ?????? ?? ???? ????? ?????? ?????
??????? ????? ?? ?????? ??? ???? ?????
10???? ?????
- ????? ?????? ????? ?? ???????? (???, ??????
???????) ?? ?????? ?????, ?? ??????? ?????? - ??????? ?????? ????????, ?????, ??????, ?????
???' - ?????? ????? ????? ????, ????? ???'
- ?? ??? ??? ?????? ???? ??????? ???
- ?? ??? ??? ?????? ???? ?????? ???
11???? ?????Levels of Abstraction
- ????? ????? ???? ???? ?? ?????
- ???? ????? (Physical Schema)
- ???? ?????? (Conceptual Schema)
- ???? ???? ????? ?? ?? ???????
- ????? (Views)
- ??? ????? ??????, ??? ??? ??? ?????? ??? ????????
?????? ???? ????????? ???????
12Levels of Abstraction
- ?? ??? (View) ???? ???? ????? ??????? ?????? ????
?? ??????? - ?????, ?? ???????? ????? ???? ???? ????? ??? ????
????? ???????
View 1
View 2
View 3
Conceptual Schema
Physical Schema
13 ???? ??? ???? ??????
- ????? ?????? ?????? ??????? ??????? ????? ???
??????, ?????? - Data Definition Language (DDL)
- ?????? ??????? ?- SQL
- ??????? ?? ????? ?????? ?????? ????? ?? ?? ??????
?? ?? ??? ???? ???????
14 ???? ???? ???? ???? ????? ?
- ??? ????? ?? ?? ???? ???????
(Data Independence) - ?? ???? ??????? ?????? ???????? ???????? ???? ???
?? ??????? ?? ???? ?????? ?? ?????? (????? ??????
???? ?? ?????? ??? ?????) - ????? ?????? ???? ?????? ????? ???????
15 ?????? ????? ?????? ???? ?????? ?????
- ???? ?????? ????? ???? ???? ?????
- ??? ??????? ????? ?????? ?????? ?????? ??????
- ?????? ???? ?????? ("?????") ??-?????
- ????? ????????? (backup recovery)
- ????? ??????? (data integrity)
- ????? ???? (data security) ???????
(authorization) - ??? ?????? ?? ?????? (views) ?????? ???? ??????
16???? ?????? ????????? ??????? ???????
- An Introduction to Schema Design
- The Entity-Relationship Model
17??? ????? ???? ?? ??? ???????
- ???? ?? ??? ?????? ???? ??????
- ????? ????? ???? ????? ?? ?????? (???, ??????
???????????) ?? ?????? ??? ??????? - ????? ????? ????? ???? ????? ?? ??????? (classes)
??? ?????? ??????, ??? - ISA Hierarchy (Inheritance Hierarchy)
- Aggregation (or Composition) Hierarchy
18???? ???? ?????
- ???? ?????? ?? ???? ???
- ????? ?? ??? ?????? ???? ?????? ??????? ?? ??????
?????? ???? - ????? ?? ??? ??? ????? ??????????? (???, ????
???????) ?? ???? ????? ????? ??????, ???? - ?- type ?? ?? ????????
- ?? ???? (????? ?? ?? ??? ????? ????? ?? ????
??????????) - ???? ...
19????? ??? ?? ????? ?????
course sid tid
os 202 20
calculus 450 10
db 202 20
db 240 20
year sname sid
3 white 240
3 jones 202
1 adams 450
dept tname tid
math cohen 10
cs levy 20
????? ?? ???? ?????? ??????? ?? ?????
?????? tid,sid,course sid,sname,year tid,tna
me,dept
20????? ??? ?????
- ????? ???? ??? ?????? ???????, ????? ??? ?????
(?? ?? ?? ?? ?????? ???? ??????? ?????? ??????) - ????? ??? ?? ??? ?????? ???? ?? ?? ?????
?????????? (methods) - ????? ????? ?????? ????? ???? ????? ?????
21????? ?????? ????? (??? ?? ?????) ????? ????
?????? ?????? ????? ?????
- ????? ??????? ???? ?? ???? ?? ????? ????? ??????
?????? ????? - ??????, "????? ????????????" ????
- ????????
- ?????
- ??????
- ???? ?????
- ????? ????
- ?????? ????
- ????...
22???? ????? ???????Entity-Relationship Model
- ???? ??????? ??????? ??? ???? ?????? ?????? ?????
?????, ?????? ????? ???? ??????? - ???? ??????? ??????? ???? ????? ?????? ??????
????? ????? ?? ??????? ????? - ???? ????????
- ????? ?????? ????? ?????? ?????
23?????
- ???? ?????? ????? ???? ????, ????? UML
(Universal Modeling Language) - ????? ???? ?? ??? ?????? ???? ???? ?????? ????
????? - ????? ????? ????? ????? ???? ??????? ???????
- ????? ?????? ??"? ????? ?????
- ?????? ???? ??? ?????? ?????? ????? ????? (?? ??
????? ????)
24??? ???? ?? ???? ??????? ???????
- ????? ????? ??????? ??????? ??? ???????
- ????? ???????
- - ???????? - ??????
- - ????? - ???? ?????
- ????? ??????
- - ??? ??? ?????? ?????????
- - ??? ??? ?????? ??????
- - ??? ??? ?????? ????? ?????
25???? ?????? ??????Entity and Entity Set
- ???? ??? ??? ????? ????? ???? ?? ??????
- ??????, ?????? ??? ???? ???? ???????
- ??, ?????, ????? ????, ?? ???, ???? ???? ???'
- ?? ???? ????? ?????? ????? ??? ????? ?????? ?????
???? ????? ?? ?????? ???????, ?????? - ?????? ????? ?"? ??, ????? ???? ??? ???
- ???? ????? ?????? ?"? ??' ???? (?? ??' ??????)
- ?? ??????? ????? ??? ?????? ?????? ?????? ???
- ??????, ????? ??????? ?? ?????????
26???? ?????? ??????Entity and Entity Set
??? ??? ??????? ??? ????? ?? ?????? ?? ???? ????
?????
- ???? ??? ??? ????? ????? ???? ?? ??????
- ??????, ?????? ??? ???? ???? ???????
- ??, ?????, ????? ????, ?? ???, ???? ???? ???'
- ?? ???? ????? ?????? ????? ??? ????? ?????? ?????
???? ????? ?? ?????? ???????, ?????? - ?????? ????? ?"? ??, ????? ???? ??? ???
- ???? ????? ?????? ?"? ??' ???? (?? ??' ??????)
- ?? ??????? ????? ??? ?????? ?????? ?????? ???
- ??????, ????? ??????? ?? ?????????
27????? ?????? ?"? ??????
- ???? ????? ???? ?"? ?????, ??????
- ???? ??????
- ?? "???? ???"
- ????? "????? ???? 107 ???????"
- ????? ???? "7.8.78"
- ?? ??? "????"
- ???? ???? "1673040"
- ????? (???? ???, ????? ???? 107 ???????, 7.8.78,
????, 1673040)
28????? ?????? ?"? ??????
????? ?? ??????? ????? ???? ??? ????? ???
- ???? ????? ???? ?"? ?????, ??????
- ???? ??????
- ?? "???? ???"
- ????? "????? ???? 107 ???????"
- ????? ???? "7.8.78"
- ?? ??? "????"
- ???? ???? "1673040"
- ????? (???? ???, ????? ???? 107 ???????, 7.8.78,
????, 1673040)
29???? (Key) ?? ????
- ????? ?? ????? ?????? ????? ???? ????? ??? ?????
????? ???? (Key) - ??????, ??' ?????? ??? ???? ?? ??????
- ???? ???? ??? ???? ?? ????, ??? ?? ?? ???? ????
????, ?? ?????? ????? ??? ?????? ????? (???????
?????) ?? ???? ??
30??? ?????? ?????Relationship Relationship Set
- ??? ???? ????? ?? ?????? ???? ??????? ???, ??????
- ??????? "??? ???" ???? ?? ????? "?????? ?????"
????? ????? "????? ???" - ??? ??? ?????, ??? ??? ???? ??????
- ????? ?????? ????????
- ??????? "??? ???" ???? ?? ????? "?????? ?????"
- ????? "????? ???" ???? ?? ????? "?????? ?????"
- ?? ?????? ????? ??? ?????? ?????? ???
31??? ?????? ?????Relationship Relationship Set
?? ????? ???? ????? ???? ????? ????? ??? ?????
??? ?? ??? ????? ????????? ???? ???? ?? ?? ?????
???????
- ??? ???? ????? ?? ?????? ???? ??????? ???, ??????
- ??????? "??? ???" ???? ?? ????? "?????? ?????"
????? ????? "????? ???" - ??? ??? ?????, ??? ??? ???? ??????
- ????? ?????? ????????
- ??????? "??? ???" ???? ?? ????? "?????? ?????"
- ????? "????? ???" ???? ?? ????? "?????? ?????"
- ?? ?????? ????? ??? ?????? ?????? ???
32????? ????? ?"? ??????
- ???? ????? ??? ?"? ?????, ??????
- ???? ??????? "??? ???" ???? ?? ????? "??????
?????" ????? ????? "????? ???" - ?????? (??? ???, ?????? ?????, ????? ???)
- ???? ??????? "??? ???" ???? ?? ????? "??????
?????" - ?????? (??? ???, ?????? ?????)
- ???? ????? "????? ???" ???? ?? ????? "??????
?????" - ?????? (????? ???, ?????? ?????)
33????? ????? ?"? ??????
????? ?? ?????? ????? ???? ??? ????? ???
- ???? ????? ??? ?"? ?????, ??????
- ???? ??????? "??? ???" ???? ?? ????? "??????
?????" ????? ????? "????? ???" - ?????? (??? ???, ?????? ?????, ????? ???)
- ???? ??????? "??? ???" ???? ?? ????? "??????
?????" - ?????? (??? ???, ?????? ?????)
- ???? ????? "????? ???" ???? ?? ????? "??????
?????" - ?????? (????? ???, ?????? ?????)
34???? ????? ??????? ??????? ????? ?????
- ??? ?????? ???? ????? ?? ????? ?????? ??? ?????
????? ?"? ??? ????? - ????? ?????? ?? ????? ?????? ??????
35???? ???? ?????
- ????? ?? ???? ????? ????????
- ????? ?? ??? ????? ????????
- ?? ??? ????? ????? ????? (Attribute) ???? ???
?????? ??? ?????? ?????, ??? ?? ????? ????? ?? ???
36 ??? ?- ISA
- ????? ??????? ??????? ?? ??? ????? ????? ??? ?-
ISA (is a) - ??? ?? ???? ?? ???????? ??????
(Inheritance Hierarchy) ?????? ??? ?????? ??
??????, ?????? - ????? ??????? ?? ?? ?????????
- ????? ??????? ?? ????????? ????? ?????
- ????? ??????? ?? ????????? ????? ???
- ????? ??????? ?? ????????? ??????? ?????? ?????
37 ????? ????? ??? ?????
- ?????? ?????? ????? ??? ?????, ???? ????? ???
????? ????? ?? ??? ?- ISA - ????? ?????? ?????? ??????
38 ??????
- ???? ??????? ??????? ???? ?? ????? ????? ??????
?? ?????? ??????? ?? ????? - ??? ????? ??? ??? ?- ISA
- ???? ????? ?? ????? ?????? ??? ????? ????? ????
?????, ????? - ???? ????? ???? ?? ??? ?????? ???? ?"? ????? ????
????? ?? ????? ????? ??????? ?????? ??????,
?????? ?????? ????? ?????
39????? ?????? ?????? ?????? ??????
- ???? ????
- ???? ?????? ?? ????
- ???? ?????
- ???? ?????
- ??????? ?? ?????? ??????
- ???? ...
40???? ????? ???? ?? ??? ?????? ??? ???? ????
- Why Is It Difficult to Design a Database Schema?
41?????? ?????
- ???? ????? ?? ?????? ????? ??????
- ????? ?? ?????
- ?????
- ???? ????? ????? ???? ?????????? (??????)
- ???????
- ????? ????? (???? NULL)
- ???? ????? ?? ?????????? (?- methods)
42???? ????? ?? ?????? ????? ??????
- ????? ???? ????? ????? ?????, ?????? ???? ????
?????? ??????? ???? ???? ???? ????????? ?????
??????? ?? ?????? - ???? ?????? ?????? ?????? ?????? ????? (???? ?"?
?????? ??????) - ????? ???? ????? ?? ?????? ??????? ??????? ??????
???? ?????? ??????? - ??????, ????? ??????? ?????? ?????? ?? ?????
43???? ?????? ?? ????? ?????? ?????? ?? ???????
??? ???????
- ?? ???? ?????? ????? ?????? ????? ?????? (?????
????? ??????) ??? ???? - ???? ??????? ????? ?????? ???? ????? ?? ?? ???
- ?????? ???? ????? ?? ????? ?????
- ??????????
- ??? ???
44?? ???? ??????
- ???? ???? ????? ???? ?? ????? ??? ??????? ????
?????? - ?????? ???? ????? ??
- ??????? ?? ????? ????? ????? ???????
- ??????? ?? ?????
- ??????, ??? ???? ?????? ??? ????? ???? ?????
????????? - ????? ????? ???? ?? ???? ??
45????? ?? ?????
- ????? ????? ?? ??????? ????? (toy examples) ????
????? ????? ??? ???? ???? ????? ??????? ??? ??? - ????? ????? ????? ???? ?????? (?? ?? ????)
??????? ????? ????? ??????? ?? ?????? ??????
?????? ??? ??? - ?????? ????? ?????? ???? "?????" ?? ????? ???????
????? ??????? ?? ??? ???????
46?????
- ??? ?????? ????? ?? ?????? ???????? ???? ISA
(inheritance), ??? ???? ?? ?????? ???? - ????? ?? ?????????
- ????? ????????? ????? ?????
- ????? ????????? ????? ???
- ????? ????????? ????? ?????
- ????? ????????? ??????? ?????? ????? (?? ?????
??? ?' ???? ????? ???? ????? ????? ???? ??? ???
????? ????? ??? ????? ????? ?????) - ????? ????????? ??????? ?????????? (?? ?????
????? ??? ???? ????? ???????, ??? ???? ???? ???
???? ?????) - ????? ????????? ??????? ???????????
47?????
?? ???? ?????? ????? (multiple inheritance)
- ??? ?????? ????? ?? ?????? ???????? ???? ISA
(inheritance), ??? ???? ?? ?????? ???? - ????? ?? ?????????
- ????? ????????? ????? ?????
- ????? ????????? ????? ???
- ????? ????????? ????? ?????
- ????? ????????? ??????? ?????? ????? (?? ?????
??? ?' ???? ????? ???? ????? ????? ???? ??? ???
????? ????? ??? ????? ????? ?????) - ????? ????????? ??????? ?????????? (?? ?????
????? ??? ???? ????? ???????, ??? ???? ???? ???
???? ?????) - ????? ????????? ??????? ???????????
???? ?? ?? ????? ??? ???? ??? ?????? ?????, ?? ??
?????? ???????? ?? ?????? ??? ?????
48???? ????? ????? ???? ?????????? (??????)
??? ???? ???? ??? ?? ?? ????? ??? ????
- ????? ???? ???? ???? ?? ?????? ?????
- ??' ????, ?? ????, ??????, ??? ?? ????? ??????
????? ??????? ???????? ????, ??' ??????
???? ??????? ??? - ?????, ???? ????? ?????? ?????? ?????
- ??????(??) ??? ???? ?????, ?????, ????? ????????
(?? ?? ???? ????? ?? ?? ???? ?????? ???? ??? ????
??????? ????) - ??? ???? ??? ??? ??????? ??? ??? ISA?
???? ???? ????? ????
???? ?????? ???? ????
49???? ????? ????? ???? ?????????? (??????)
?? ????? ??? ????? ???????, ????? ???? ???????
???? ????? ????
- ????? ???? ???? ???? ?? ?????? ?????
- ??' ????, ?? ????, ??????, ??? ?? ????? ??????
????? ??????? ???????? ????, ??' ??????
???? ??????? ??? - ?????, ???? ????? ?????? ?????? ?????
- ??????(??) ??? ???? ?????, ?????, ????? ????????
(?? ?? ???? ????? ?? ?? ???? ?????? ???? ??? ????
??????? ????) - ??? ???? ??? ??? ??????? ??? ??? ISA?
50???? ????? ????? ???? ?????????? (??????)
???? ??? ??? ?????? ???? ????. ????? ???? ???
?????? ??????? ?????? ??? ???
- ????? ???? ???? ???? ?? ?????? ?????
- ??' ????, ?? ????, ??????, ??? ?? ????? ??????
????? ??????? ???????? ????, ??' ??????
???? ??????? ??? - ?????, ???? ????? ?????? ?????? ?????
- ??????(??) ??? ???? ?????, ?????, ????? ????????
(?? ?? ???? ????? ?? ?? ???? ?????? ???? ??? ????
??????? ????) - ??? ???? ??? ??? ??????? ??? ??? ISA?
51???????
- ????? ????? ?????? ???? ????? ?? ???????? ??????
????????? ????? ????? ????? ???? ????? ??????? - ??? ???? ????? ???? ????? ???? ??? ????
- ??? ???? ????? ???? ?????? ????? ??? ?????
- ????? ???????? ??? ???"? ??? ???? ?????? ???????
??????? - ??? ??? ?????? ?? ????? ?? ??? ?? ??? ???? ????
?????? ???? ?? ??????
52????? ????? ?? ?? ?????? (???? NULL)
- ??? ??? ?? ???????? ???? ????? NULL?
- ?? ???? ?? ?????? ???
- ???? ????? ?? ?????? ????? NULL
- ?? ?????? (???? ????????? ?? ???????) ????? ?????
???? ???? ?????? ????? ????? NULL - ???? NULL ??????? ???? ?????? ?????? ?? ??????
??????? - ???? ???? ?? ??????? ????? ???? ???? ?? ???
?????????? ????
53?????
- ??? ????? ?? ?? ????????? ?? CS ???? ????? ??
????? - DEPT CS
- ??? ????? ?? ?? ????????? ?? CS ?? ??? ?????? ???
?- CS ???? ????? ?? ????? - DEPT CS OR DEPT IS NULL
- ??? ?????? ????? ???? ??? ??????? ???? ????
?????? - Mode ????? ?? ??????? ???????
- Mode ????? ?? ??????? ????????
54???? ????? ?? ?????????? (?- methods)
- ???? ???? ?????? ??????????? ???? ???? ?? ??????,
???????? ???' - ???? ????? ???? ?? ?????? ????? ???? ?- CS?
- ?? ???? ?? ???? ???? ???? ???????, ?? ???
???????? ???? ????? ???? method ????? ??? ??????
???? ????? - ?? ???? ????? ?????? ???? ???? ?????? ???? ???
- ??????, ????? ????? ???? ??? ???? ???? ????
??????????? ??? ???? ???? ?- CS
55????? ??????
- ????? ???? ?????? ????? ?? ?? ?????, ???? ??????
????? ???? ??? ??? ?? ????? ??????? ?????? - ??? ????? ???? ???? ???????? ??? ???? ???? ?- CS?
- ?? ??, ??? ???? ???? ?????? ??????? ????? ?????
????????? - ????? ??????? ??? ????? ????? ?????