1 2 3 4 5 6 7 8 9 10 11
begin; create table user_planned_reports ( id serial not null primary key, user_id int references users(id) not null, report_id int references problem(id) not null, added timestamp not null default current_timestamp, removed timestamp ); commit;