Databases are relational. The concept of a relational database

The advent of computer technology in our time marked an informational upheaval in all spheres of human activity. But in order to ensure that all information does not become unnecessary garbage on the global Internet, a database system was invented in which materials are sorted, systematized, as a result of which they are easy to find and submit to subsequent processing. There are three main varieties - distinguish relational, hierarchical, and network databases.

Fundamental models

, , , . , 50, , , . ?

, . . , . , , . . .

relational database structure








1970- . , , , , , - , . ? ( . relatio) . . , . ? , .

relational database concept




, , , , - , , .

, Workbench, PhpMyAdmin, Case Studio, dbForge Studio. SQL-. , .





relational database design




, ,

- , :

  • = ;
  • = = = ;
  • = = = ;
  • = = .

relational database record




, .

  1. . , , . . , .
  2. – , , . .
  3. - , .
  4. . . – , .

relational database table




, , database:

  • . .
  • .
  • .
  • .
  • .
  • . .

, , , . .

. , . , . . , "", " ". . . – . , . NULL-. . , , – . .

relational database field types




12345
_1_1_1_2_1_3_1_4_1_5
_2_1_2_2_2_3_2_4_2_5
_3_1_3_2_3_3_3_4_3_5

SQL . , . – . , .

1. , ( - 1).

2. , 1, (2).

3. , 2, (3 ).

:

2 :

  • «-». №1 . , «», .

relational databases




  • «-» .
  • « », , , , . . « » .

. , primary key. ? – , . , , . , , .

, (foreign key). , . . , 2 : «» «». «» : «ID », «» «». «» , «», «» « ». ID , . «» «» «» , ID «», .

, . «».

""

ID

111

-41

222

-72

333

-41

444

-72

, . "-41", "-72", "", , , . «».

""

-41

3,0

2-27-36

-72

3,8

2-36-82

-41

3,9

2-54-78

-72

4,7

2-65-25

, . , . integer, char, vachar, date . "" ID . . , "" , ID . . « ». , . ID- , .




All Articles