insert new record

with foreign key constraints