Fix column foreign key data type, issiue #658

fix for issue #658

make client_id in access_token and approved_site_scope,
whitelisted_site_id in approved_site the same type at the key they
refer to.