Forum Discussion

AmanMalhotra's avatar
2 years ago

How to get only Messages where some specific custom field have value?

Hi Team,

I have a custom field added by Khoros in the messages object, I want to get only Messages where that specific custom field has value.

Sample query:
select c_abcd from messages where c_abcd!=""

I don't want to get all messages and then in the loop filter the messages which don't have any value.

Is there any direct API or solution to get the messages where the c_abcd custom field has some value?

Any related replies would be appreciated.

Regards
Aman

11 Replies

  • The exact query that you shared should work, basically c_abcd!="" would return all the messages with some value populated in this field. If possible you can also add certain Sort and Limit to structure the response.