Problems with foreign keys. Revise.