Fix foreign key in postgresql schema
Merge pull request #517 from mattes/patch-1

Fix foreign key in postgresql schema