Service Cloud Query Parameter ROQL Is Not Working (REST API) (Doc ID 2286969.1)

Last updated on AUGUST 16, 2017

Applies to:

Integration Cloud Service - Version N/A and later
Information in this document applies to any platform.

Goal

On : ICS version, General issues

Service cloud query parameter ROQL is not working (REST API)

ServiceCloud is returning an error ,when use ROQL in the query parameters of rest connection of ICS to fetch contact id information .From logs,  found that proper SQL input in the query parameter is passed but still getting an error.  



  select id,customFields.c.hcm_identifier,createdTime,updatedTime from contacts where customFields.c.hcm_identifier='300000002189182' order by id desc
  

Fault:
OSB-380001<genericRestFault><errorCode>400</errorCode><errorPath><![CDATA[GET https://hmlandregistry-hrsupportdesk--tst1.custhelp.com/services/rest/connect/v1.3/queryResults?query=select+id%2CcustomFields.c.hcm_identifier%2CcreatedTime%2CupdatedTime+from+contacts++where+customFields.c.hcm_identifier%3D%27300000002189182%27+order+by+id+desc returned a response status of 400 Bad Request]]></errorPath><instance><![CDATA[{ "type": "https://hmlandregistry-hrsupportdesk--tst1.custhelp.com/services/rest/connect/exceptions/OSC-CREST-00019", "title": "Invalid query parameter value", "status": 400, "detail": "This query is not supported: near \"from\": syntax error", "instance": "https://hmlandregistry-hrsupportdesk--tst1.custhelp.com/services/rest/connect/v1.3/queryResults?query=select+id%2CcustomFields.c.hcm_identifier%2CcreatedTime%2CupdatedTime+from+contacts++where+customFields.c.hcm_identifier%3D%27300000002189182%27+order+by+id+desc", "o:errorCode": "OSC-CREST-00019" } ]]></instance></genericRestFault> RouteNode1response-pipeline
]]

Same query  when tried in SOAP UI its working but the  same in ICS is giving  error.
 

[2017-06-27T22:04:23.306+00:00] [OJDL] [NOTIFICATION:16] [ODL-52001] [oracle.core.ojdl.FileLogWriter] [org: Oracle] [host: nl1z14-ics-ics20376-ics-ms1.opcics.z14.nldc1.oraclecloud.com] [nwaddr: 10.197.113.2] [tid: [ACTIVE].ExecuteThread: '25' for queue: 'weblogic.kernel.Default (self-tuning)'] [userId: paasusr] deleting log file: ics_server1-diagnostic-1986.log, size: 10476180 bytes
[2017-06-27T22:04:23.300+00:00] [ics_server1] [ERROR] [OSB-381967] [oracle.osb.transports.jca.jcatransport] [tid: [ACTIVE].ExecuteThread: '25' for queue: 'weblogic.kernel.Default (self-tuning)'] [userId: srikanth.g@capgemini.com] [ecid: c1ef99cb-f270-4527-b931-7ecf5df3e213-000a63a0,0:5] [APP: Service Bus JCA Transport Provider] [oracle.soa.tracking.FlowId: 5200114] [oracle.soa.tracking.InstanceId: 570785] [oracle.soa.tracking.SCAEntityId: 51456] [composite_name: EMPSERVICECLOUDCLONEDEL!01.00.0000] [FlowId: 0000Lnf_O2SBh49pRcp2id1PGhr800001m] Invoke JCA outbound service failed with application error, exception: com.bea.wli.sb.transports.jca.JCATransportException: <genericRestFault><errorCode>400</errorCode><errorPath><![CDATA[GET https://hmlandregistry-hrsupportdesk--tst1.custhelp.com/services/rest/connect/v1.3/queryResults?query=%0Aselect%2520id%2520from%2520contacts%0A returned a response status of 400 Bad Request]]></errorPath><instance><![CDATA[{[[
"type": "https://hmlandregistry-hrsupportdesk--tst1.custhelp.com/services/rest/connect/exceptions/OSC-CREST-00019",
"title": "Invalid query parameter value",
"status": 400,
"detail": "This query is not supported: near \"%\": syntax error",
"instance": "https://hmlandregistry-hrsupportdesk--tst1.custhelp.com/services/rest/connect/v1.3/queryResults?query=%0Aselect%2520id%2520from%2520contacts%0A",
"o:errorCode": "OSC-CREST-00019"
}
]]></instance></genericRestFault>
; nested exception is:
<genericRestFault><errorCode>400</errorCode><errorPath><![CDATA[GET https://hmlandregistry-hrsupportdesk--tst1.custhelp.com/services/rest/connect/v1.3/queryResults?query=%0Aselect%2520id%2520from%2520contacts%0A returned a response status of 400 Bad Request]]></errorPath><instance><![CDATA[{
"type": "https://hmlandregistry-hrsupportdesk--tst1.custhelp.com/services/rest/connect/exceptions/OSC-CREST-00019",
"title": "Invalid query parameter value",
"status": 400,
"detail": "This query is not supported: near \"%\": syntax error",
"instance": "https://hmlandregistry-hrsupportdesk--tst1.custhelp.com/services/rest/connect/v1.3/queryResults?query=%0Aselect%2520id%2520from%2520contacts%0A",
"o:errorCode": "OSC-CREST-00019"
}
]]></instance></genericRestFault>

Solution

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms