Обновить lab1/lab_1.txt

This commit is contained in:
2026-10-20 07:30:56 +00:00
parent 6f6b3ca404
commit 6965448f37
+62 -62
View File
@@ -1,63 +1,63 @@
Table card { Table card {
card_id int [primary key, not null] card_id int [primary key, not null]
card_name text [not null] card_name text [not null]
card_stage text [not null] card_stage text [not null]
card_hp int [not null, check: `card_hp > 0`] card_hp int [not null, check: `card_hp > 0`]
card_number_in_pokedex int card_number_in_pokedex int
card_type text card_type text
card_height_m numeric [not null, check: `card_height_m > 0`] card_height_m numeric [not null, check: `card_height_m > 0`]
card_weight_kg numeric [not null, check: `card_weight_kg > 0`] card_weight_kg numeric [not null, check: `card_weight_kg > 0`]
card_retreat_cost int [not null] card_retreat_cost int [not null]
card_year_release int [not null] card_year_release int [not null]
card_number_in_set text [not null] card_number_in_set text [not null]
set_id int [not null] set_id int [not null]
illustrator_id int [not null] illustrator_id int [not null]
element_type_id int [not null] element_type_id int [not null]
} }
Table card_set { Table card_set {
set_id int [primary key, not null] set_id int [primary key, not null]
set_code text [unique, not null] set_code text [unique, not null]
set_name text [not null] set_name text [not null]
set_total_card text set_total_card text
set_release_date date [not null] set_release_date date [not null]
} }
Table attack { Table attack {
attack_id int [primary key, not null] attack_id int [primary key, not null]
attack_name text [not null] attack_name text [not null]
attack_base_damage int attack_base_damage int
attack_damage_modifier text attack_damage_modifier text
attack_effect text attack_effect text
} }
Table element_type { Table element_type {
element_type_id int [primary key, not null] element_type_id int [primary key, not null]
element_type_name text [unique, not null] element_type_name text [unique, not null]
} }
Table illustrator { Table illustrator {
illustrator_id int [primary key, not null] illustrator_id int [primary key, not null]
illustrator_name text [unique, not null] illustrator_name text [unique, not null]
} }
Table card_attack { Table card_attack {
card_attack_id int [primary key, not null] card_attack_id int [primary key, not null]
card_id int [not null] card_id int [not null]
attack_id int [not null] attack_id int [not null]
} }
Table attack_energy_cost { Table attack_energy_cost {
attack_energy_cost_id int [primary key, not null] attack_energy_cost_id int [primary key, not null]
attack_id int [not null] attack_id int [not null]
element_type_id int [not null] element_type_id int [not null]
energy_quantity int [not null, check: `energy_quantity > 0`] energy_quantity int [not null, check: `energy_quantity > 0`]
} }
Ref card_set: card.set_id > card_set.set_id Ref card_set: card.set_id > card_set.set_id
Ref card_illustrator: card.illustrator_id > illustrator.illustrator_id Ref card_illustrator: card.illustrator_id > illustrator.illustrator_id
Ref card_element_type: card.element_type_id > element_type.element_type_id Ref card_element_type: card.element_type_id > element_type.element_type_id
Ref attack_energy: attack_energy_cost.attack_id > attack.attack_id Ref attack_energy: attack_energy_cost.attack_id > attack.attack_id
Ref attack_energy_element_type: attack_energy_cost.element_type_id > element_type.element_type_id Ref attack_energy_element_type: attack_energy_cost.element_type_id > element_type.element_type_id
Ref card_attack_card: card_attack.card_id > card.card_id Ref card_attack_card: card_attack.card_id > card.card_id
Ref card_attack_attack: card_attack.attack_id > attack.attack_id Ref card_attack_attack: card_attack.attack_id > attack.attack_id