Merge pull request #2 from JonoEPD/master

changes from this morning
now we handle foreign keys with ONE tuple properly.