i tried to insert an attachment with file_id equal to 50 which is not found in file table and i didn't get errors????
so i realized that there is no foreign key, they set just the columns names but in the database they are not declared.
even i tried to export the database to sql file so that i could see the relations on workbench, i didn't found any declaration for foreign keys in the exported file.