Table.add_foreign_key now checks join condition is actually fulfilled before creating foreign key.
Will now only cast column value if necessary, i.e. when target type and actual type are different.