it was *REALLY* hard

for the future: do not touch foreign keys in GUI with qt, it's crazy
waste of time