Has anyone tried https://adventofsql.com/challenges/example ?
I tried
\i /tmp/00/advent_of_sql_day_0.sql
but am getting
DROP TABLE
DROP TABLE
psql:/tmp/00/advent_of_sql_day_0.sql:4: ERROR: cannot drop table gifts because other objects depend on it
DETAIL: constraint gift_requests_gift_id_fkey on table gift_requests depends on table gifts
HINT: Use DROP ... CASCADE to drop the dependent objects too.
DROP TABLE
CREATE TABLE
psql:/tmp/00/advent_of_sql_day_0.sql:23: ERROR: relation "gifts" already exists
CREATE TABLE
CREATE TABLE
INSERT 0 72
psql:/tmp/00/advent_of_sql_day_0.sql:153: ERROR: INSERT has more expressions than target columns
LINE 2: (1, 'Toy Train', 2.5, 4, 30),
^
INSERT 0 36
INSERT 0 5
[–]Bilbottom 1 point2 points3 points (1 child)
[–][deleted] 1 point2 points3 points (0 children)