parsing a XML document
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-14-2017 11:10 AM
can you please guide me on this.
1) I created a Soap OutBound Message.
2) recieved a long response(xml) for a given request.
3) i want to put this in a scheduled job.
4) I want to extract the a single node data from that and push it into cutom table.
5) I copied the preview script and pasted in scheduled script.
5) I want to parse the xml data and extrat the contents of the perticular node.
Please guide me on extracting the node data.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-14-2017 12:21 PM
Make use of XMLHelper
var helper =new XMLHelper(xmlString);
var obj = helper.toObject();
logObj(obj,"*")function logObj(obj, sep){
for(x in obj){
if(typeof obj[x]!="function"){
gs.log(sep + x +":: "+ obj[x]);} //here x is the tag, obj[x] is the tag value
logObj(obj[x], sep +"*");}}

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-14-2017 12:16 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-14-2017 12:21 PM
Cam I have your whats app number......if you don't mind.
On Dec 15, 2017 1:47 AM, "gowrisankar" <community-no-reply@servicenow.com>
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-14-2017 07:48 PM
Can you please gu ide further....for your first response i am getting null value
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎12-14-2017 08:06 PM
Hey I got the firstfield .....similarly i want read multiple fields......please guide me.......i mean there are 20 portfolios ...so how to capture all ...is it by using for loop.