直接上代码:
CREATE TABLE orders (
order_id SERIAL,
dish_name TEXT,
customer_id INTEGER REFERENCES customers (id)
);
https://tableplus.io/blog/2018/08/postgresql-how-to-add-a-foreign-key.html
直接上代码:
CREATE TABLE orders (
order_id SERIAL,
dish_name TEXT,
customer_id INTEGER REFERENCES customers (id)
);
https://tableplus.io/blog/2018/08/postgresql-how-to-add-a-foreign-key.html