com.glide.processors.soap.SOAPProcessingException: Field(s) present in the query do not have permission to be read

Atchaang
Tera Contributor

I am using SOAPUI to query servicenow data table.
Data are returned for most of tables (cmdb_ci,incident etc...) but for sys_choice table, when I try the method getRecords, an error is raised :
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:sys="http://www.service-now.com/sys_choice">
<soapenv:Header/>
<soapenv:Body>
<sys:getRecords>
<!--Optional:-->
<sys:element>state</sys:element>
<sys:language>en</sys:language>
<!--Optional:-->
<sys:name>incident</sys:name>
</sys:getRecords>
</soapenv:Body>
</soapenv:Envelope>

Error is raised (only for this table sys_choice)
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
<SOAP-ENV:Header/>
<SOAP-ENV:Body>
<SOAP-ENV:Fault>
<faultcode>SOAP-ENV:Server</faultcode>
<faultstring>com.glide.processors.soap.SOAPProcessingException: Field(s) present in the query do not have permission to be read</faultstring>
<detail>com.glide.processors.soap.SOAPProcessingException: Field(s) present in the query do not have permission to be read</detail>
</SOAP-ENV:Fault>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

Any idea about this error ?

Thanks & regards

 

7 REPLIES 7

Ashutosh Munot1
Kilo Patron
Kilo Patron

Hi,

This is Permission issue. The user do not have permissions to read the record and choices.


Thanks,
Ashutosh

Hi
Thank you for your feedback.
Which ServiceNow role/group to give to my ServiceNow API account to have access content of the sys_choice table ?   
If I use sys_choice.list, I and my API account can see only the Label field.
Maybe other fields are not allowed to see ?
Regards  

Hi,

Check table.* ACL.


Thanks,

Ashutosh

Hayo Lubbers
Kilo Sage

Hi,

 

Why do you prefix your fieldnames?

<sys:element>state</sys:element>
<sys:language>en</sys:language>
<sys:name>incident</sys:name>

instead of 

 <element>state</element>
 <language>en</language>
 <name>incident</name>

 

Resulting in something like:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:choice="http://www.service-now.com/sys_choice">
   <soapenv:Header/>
   <soapenv:Body>
      <choice:getRecords>
        <element>state</element>
        <language>en</language>
        <name>incident</name>
      </choice:getRecords>
   </soapenv:Body>
</soapenv:Envelope>
 
Cheers,
Hayo