generated from admin/template
73 lines
1.7 KiB
Plaintext
73 lines
1.7 KiB
Plaintext
Table card {
|
|
set_id int [pk, not null]
|
|
element_id int [primary key]
|
|
card_id int [primary key]
|
|
card_name text [NOT NULL]
|
|
card_stage text [NOT NULL]
|
|
card_hp int [NOT NULL, check:`card_hp>0`]
|
|
card_num_pokedeks int [NOT NULL]
|
|
card_category text [NOT NULL]
|
|
card_weight numeric [NOT NULL, check:`card_weight>0`]
|
|
card_height numeric [NOT NULL, check:`card_height>0`]
|
|
card_retreat_cost int [NOT NULL]
|
|
card_year date
|
|
illustrator_id int [primary key]
|
|
}
|
|
Table card_set {
|
|
set_id int [pk, not null]
|
|
card_code_set int [ primary key]
|
|
card_set_name text [NOT NULL]
|
|
card_date date
|
|
}
|
|
Table attack {
|
|
element_id int [primary key]
|
|
attack_id int [primary key]
|
|
attack_name text [NOT NULL]
|
|
damage int [NOT NULL, check:`damage>0`]
|
|
text_effect_attack text [NOT NULL]
|
|
attack_modificator text
|
|
}
|
|
Table element_type {
|
|
element_id int [primary key]
|
|
element_name text [NOT NULL]
|
|
}
|
|
Table illustrator {
|
|
illustrator_id int [primary key]
|
|
illustrator_name text [NOT NULL]
|
|
|
|
}
|
|
Table card_attack {
|
|
attack_id int [NOT NULL]
|
|
card_id int [NOT NULL]
|
|
card_attack_id int [pk]
|
|
|
|
}
|
|
Table element_attack {
|
|
attack_id int [NOT NULL]
|
|
element_id int [NOT NULL]
|
|
cost int [NOT NULL]
|
|
element_attack_id int [pk]
|
|
|
|
}
|
|
|
|
|
|
Ref: "card"."illustrator_id" -? "illustrator"."illustrator_id"
|
|
|
|
Ref: "element_type"."element_id" - "attack"."element_id"
|
|
|
|
Ref: "element_type"."element_id" - "card"."element_id"
|
|
|
|
Ref: "card_attack"."attack_id" > "attack"."attack_id"
|
|
|
|
|
|
Ref: "card_attack"."card_id" ?> "card"."card_id"
|
|
|
|
|
|
|
|
Ref: "element_attack"."attack_id" > "attack"."attack_id"
|
|
|
|
|
|
|
|
Ref: "element_attack"."element_id" ?> "element_type"."element_id"
|
|
|
|
Ref: "card"."set_id" - "card_set"."set_id" |