mirror of
https://github.com/Dannecron/netology-devops.git
synced 2025-12-25 23:32:37 +03:00
homework 6.2: add tasks 3-6
This commit is contained in:
14
src/homework/06-database/6.2/migration_structure.sql
Normal file
14
src/homework/06-database/6.2/migration_structure.sql
Normal file
@@ -0,0 +1,14 @@
|
||||
create table orders
|
||||
(
|
||||
id serial primary key,
|
||||
name varchar(255),
|
||||
price integer
|
||||
);
|
||||
|
||||
create table clients
|
||||
(
|
||||
id serial primary key,
|
||||
last_name varchar(255),
|
||||
country varchar(255),
|
||||
order_id integer constraint client_order_fk references orders (id) on delete cascade on update no action
|
||||
);
|
||||
Reference in New Issue
Block a user