This commit is contained in:
How
2026-09-09 13:01:30 +00:00
parent 120ac4ccb0
commit 830c61a302
+60 -16
View File
@@ -12,22 +12,22 @@ Table card_set {
card_set_release_date date [null]
card_set_total_cards int [null, check: `card_set_total_cards > 0`]
}
Table pokemon {
pokemon_id int [pk, check: `card_hp > 0`]
pokemon_attack_id int [not null, ref: > attack.attack_id]
pokemon_attack_position int [null, check: `card_attack_position > 0`]
pokemon_height numeric
pokemon_weight numeric
}
Table trainer {
trainer_id int [pk, increment]
}
Table element_type {
element_type_id int [pk, increment]
element_type_name text [not null, unique]
element_type_symbol text [null]
}
Table pokemon {
card_pokemon_id int [primary key, not null]
card_pokemon_hp int [not null, check: `card_hp > 0`]
card_pokemon_hieght numeric
card_pokemon_weight numeric
card_pokemon_name text [not null]
card_card_id int [primary key, not null]
card_pokemon_stage text [not null]
card_pokemon_evloves_from text
card_pokemon_category text
entrgy_type_id int [not null, ref: > energy_type.energy_type_id]
attack_energy_cost_id int [not null, ref: > attack_energy_cost.attack_energy_cost_id]
attack_id int [not null, ref: > attack.attack_id]
trainer_id int [not null, ref: > trainer.trainer_id]
}
Table attack {
attack_id int [pk, increment]
attack_name text [not null]
@@ -35,6 +35,35 @@ Table attack {
attack_base_damage int [null, check: `attack_base_damage >= 0`]
attack_retreat_cost int [null, check: `attack_retreat_cost >= 0`]
}
Table energy_type {
energy_quantily text [null]
element_type_id int [pk, increment]
element_type_name text [not null, unique]
energy_type_id int [increment, pk]
energy_type_icon_ur text
}
Table trainer {
trainer_id int [pk, increment]
trainer_name text [not null, unique]
trainer_type int [not null]
trainer_releaced_date date [not null]
trainer_skill text [not null]
trainer_description text [not null]
trainer_rarity text [not null]
trainer_image_url text [not null]
}
Table trainer_printed_type {
printed_type_id int [pk, increment]
printed_type_name text [unique]
}
Table element_type {
element_type_id int [pk, increment]
element_type_name text [not null, unique]
element_type_symbol text [null]
}
Table card {
card_id int [pk, increment]
@@ -47,7 +76,7 @@ Table card {
card_image_url text [null]
illustrator_id int [not null, ref: > illustrator.illustrator_id]
card_set_id int [not null, ref: > card_set.card_set_id]
pokemon_id int [not null, ref: > pokemon.pokemon_id]
pokemon_id int [not null]
}
Table card_attack {
@@ -63,3 +92,18 @@ Table attack_energy_cost {
element_type_id int [not null, ref: > element_type.element_type_id]
energy_quantity int [not null, check: `energy_quantity > 0`]
}
Table pokemon_sub {
sub_type_id int [pk, increment]
sub_type_name text [not null, unique]
sub_type_default_prize_count int [not null]
sub_type_global_rule_text text [not null]
}
Table ability_type {
ability_type_id int [pk, increment]
ability_type_name text [unique]
}
Table attack_name {
attack_name_id int [pk, increment]
attack_name_title text [unique]
}