Fixing iteritems in migrate_table