CRM-13947: fix where clause condition
Merge pull request #2324 from yashodha/4.4

CRM-13947: fix where clause condition