Happy Business Starts Here

Valued Scholar

ZOQL query error

Hi All,


I'm using ZOQL and post the following query:

select AccountNumber,Id, Name, SalesRepName, BillToId from Account


In return I get the error: which says there's a syntax error:


"errorCode" : "90005",
"message" : "There is a syntax error in one of the queries in the AQuA input",
"batches" : [ {
"localizedStatus" : "pending",
"recordCount" : 0,
"apiVersion" : "58.0",
"batchType" : "zoqlexport",
"full" : true,
"status" : "pending",
"query" : "select AccountNumber,Id, Name, SalesRepName, BillToId from Account limit 0,50;"
} ],
"useLastCompletedJobQueries" : false,
"encrypted" : "none",
"status" : "error",
"format" : "CSV",
"version" : "1.0",
"name" : "IConductQuery"



When I post the query without the BillToId field the query returns results fine.

What might be the problem?





Tags (2)
Support SME

Re: ZOQL query error

Hi @_mikeSmith if you use zoqlexport as your query type, you're working with data sources that can be pre-joined with each other, and not with the API objects where the objects structure is slightly different.


More resources on this - the first topic explains your specific example Smiley Happy






If you found my answer helpful, please give me a kudo ↑
Help others find answers faster by accepting my post as a solution √

Valued Scholar

Re: ZOQL query error

Thank you very much @Viktor, that helped.