CRM-14952, fixes for sorting

----------------------------------------
* CRM-14952: Sorting on state in search throws FATAL error: Database Error Code: Unknown column 'civicrm_state_province.name' in 'field list'
  https://issues.civicrm.org/jira/browse/CRM-14952
Merge pull request #3641 from kurund/CRM-14952

CRM-14952, fixes for sorting