Find your people. Pick a challenge. Ship something real. The CreatorCon Hackathon is coming to the Community Pavilion for one epic night. Every skill level, every role welcome. Join us on May 5th and learn more here.

Use string filters in REST API queries

srihari3
Kilo Contributor

Hi,

I am trying to filter the responses for REST query

`https://XXXX.service-now.com/api/now/table/sys_db_object?sysparam_query=sys_nameLIKEDia`

I read that the sysparm_query=column_aISNOTEMPTY would work. As documented in How do I filter empty rows with REST API?   I am trying to filter on sysparam_query=sys_nameLIKEDia and failed.

Could anyone point me to the flaw and help me filter the response on string columns.

Thank you

1 ACCEPTED SOLUTION

Alikutty A
Tera Sage

Hi,



Just add the following line in your sysparm_query



nameLIKEia



I think sys_name is not a field name?



Thank You


Please Hit Like, Helpful or Correct depending on the impact of response


View solution in original post

5 REPLIES 5

reginabautista
Kilo Sage

Hi Sri



You need to change your query to below. You should remove the sys_ and just leave 'name'. Also I think sysparm was misspelled. It should be sysparm and not sysparam




Try   this:


`https://XXXX.service-now.com/api/now/table/sys_db_object?sysparm_query=nameLIKEia