You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

ROQL querying Custom fields of Contact Object

Accepted answer
75
Views
8
Comments
edited Jun 8, 2022 8:55AM in Agent Desktop 8 comments

Content

Hi 

I have a scenario in my project to fetch the custom fields of Contact Object using Connect API(.NET)

String queryString = "SELECT Contact from Contact C where C.UpdatedTime > '" + timeToday + "' and C.UpdatedTime < '"+ timeNow + "'";

I am using queryObjects to fetch the data 

QueryResultData[] queryData = _service.QueryObjects(clientInfoHeader, queryString, objectTemplates, 10000);

But this query does not return the custom fields in the Contact object.

If I specifically mention "Select c.customfields from Contact" It throws an error "Customfields is not a primary object".

Please suggest a way to fetch customfields. And is it possible to fetch a contact based on Custom fields? 

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!