Differences between two result sets MySQL -


very beginner question haven't been able come answer after reading various resources.

i have table group_affiliations joining table between tables users , groups. relevant columns: id, user_id, group_id. doing data cleanup users assigned group_id based on location used 3 character abbreviation of city has since gone spelling out full city (ex: group_id cha assigned , group_id charlotte). users have both group_ids associated user_id still have old group_id , never assigned new one.

what efficient way of finding ids in result set:

select user_id group_affiliations group_id=oldid; 

and not in result set:

select user_id group_affiliations group_id=newid; 

select 'user_id'  'group_affiliations'  'group_id' = oldid  , 'group_id' != newid 

Comments

Popular posts from this blog

c++ - Creating new partition disk winapi -

Android Prevent Bluetooth Pairing Dialog -

VBA function to include CDATA -