We've updated the ServiceNow Community Code of Conduct, adding guidelines around AI usage, professionalism, and content violations. Read more

what is the difference between add query and add encoded query?

rajaa
Giga Contributor

o

5 REPLIES 5

Shashank Vashi1
Mega Guru

Please refer to the below code:


var filterQuery = "number="INC0001"^priority="1";


var gr = GlideRecord('u_updates');


gr.addEncodedQuery(filterQuery);


gr.query();



In this way you can run an encoded query with multiple conditions however in addquery you pass only one condition in one addquery.