generated from admin/template
Обновить works/lab-01/datainsert.sql
This commit is contained in:
@@ -7,8 +7,6 @@ card_set_amount int not null,
|
|||||||
card_set_release date not null
|
card_set_release date not null
|
||||||
);
|
);
|
||||||
|
|
||||||
select * from card_set;
|
|
||||||
|
|
||||||
insert into card_set (card_set_name, card_set_code, card_set_series, card_set_amount, card_set_release) values
|
insert into card_set (card_set_name, card_set_code, card_set_series, card_set_amount, card_set_release) values
|
||||||
('XY Базовый набор', 'XY1', 'XY', 146, '2014-02-05'),
|
('XY Базовый набор', 'XY1', 'XY', 146, '2014-02-05'),
|
||||||
('XY Огненная вспышка', 'XY2', 'XY', 106, '2014-05-07'),
|
('XY Огненная вспышка', 'XY2', 'XY', 106, '2014-05-07'),
|
||||||
@@ -19,4 +17,17 @@ insert into card_set (card_set_name, card_set_code, card_set_series, card_set_am
|
|||||||
('XY Древние истоки', 'XY7', 'XY', 98, '2015-08-12'),
|
('XY Древние истоки', 'XY7', 'XY', 98, '2015-08-12'),
|
||||||
('XY Прорыв', 'XY8', 'XY', 162, '2015-11-04'),
|
('XY Прорыв', 'XY8', 'XY', 162, '2015-11-04'),
|
||||||
('XY Тайное превосходство', 'XY9', 'XY', 122, '2016-02-03'),
|
('XY Тайное превосходство', 'XY9', 'XY', 122, '2016-02-03'),
|
||||||
('XY Столкновение судеб', 'XY10', 'XY', 124, '2016-05-02');
|
('XY Столкновение судеб', 'XY10', 'XY', 124, '2016-05-02');
|
||||||
|
|
||||||
|
create table card(
|
||||||
|
card_id int generated always as identity primary key,
|
||||||
|
card_set_id int not null default 3 references card_set(card_set_id),
|
||||||
|
card_number text not null,
|
||||||
|
card_name text not null,
|
||||||
|
card_rarity text not null,
|
||||||
|
card_type text not null,
|
||||||
|
card_image_url text not null
|
||||||
|
);
|
||||||
|
|
||||||
|
-- import data
|
||||||
|
-- а зачем я всё это пишу если результата не видно :P ладно, появляется понимание
|
||||||
Reference in New Issue
Block a user