Some fixes

1. Set value to seq of ForeignKeyMetaData.Entry
2. Updated some tests.