Encoded Query
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-17-2011 08:26 AM
What is the difference between applyEncodedQuery and addEncodedQuery?
Amit
2 REPLIES 2
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-17-2011 10:06 AM
addEncodedQuery adds the conditions before querying for results.
var query = "category=Hardware^priority=1";
var gr = new GlideRecord("incident");
gr.addEncodedQuery(query);
gr.query();
applyEncodedQuery takes the values from the query and applies them to a record.
var query = "category=Hardware^priority=1";
gr = new GlideRecord('incident');
gr.applyEncodedQuery(query);
gr.insert();
//incident created with values from encoded query
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-27-2011 01:46 AM
Thansk for this tip.