Q&A for administrators and users of the CiviCRM Constituent Relationship Management software
select ROW_NUMBER() OVER (ORDER BY Reputation DESC) As Rank, Id [User Link], Reputation, DisplayName, Location from Users where (Location like '%, MN%' or Location like '%,MN%' or Location like '% MN%' or Location like '%Minnesota%' or Location like '%Minneapolis%' or Location like '%Saint Paul%' or Location like '%St. Paul%') and Location not like '%India%' order by Reputation desc