Cisco Support Community
Showing results for 
Search instead for 
Did you mean: 

Welcome to Cisco Support Community. We would love to have your feedback.

For an introduction to the new site, click here. If you'd prefer to explore, try our test area to get started. And see here for current known issues.

New Member

Script fails after upgrade from 4.x to 8.5(1)


After upgrading from IPCCx 4.x to UCCx 8.5(1) one of my scripts is no longer working (see attached script). I reviewed the errors received and made some changes to the script (see add'l attached script). While the revised script no longer produces the error, the value received for 'Customer Region' is in a format that the script cannot read (ie, U"\n\t\t"). Can anyone help with figuring out why my original script failed to work and why the revised script returns a value in an unrecognizable format? ***Note, AreaCodes.xml file is also attached.

Everyone's tags (6)
New Member

Script fails after upgrade from 4.x to 8.5(1)

Hi all,

While working with TAC I discovered that my original script was hitting the following bug (CSCti89552):

This only confirms that I was on the right path in changing my original script to use a Create XML Document step vs the Create File Document step. TAC is not willing to provide any additional assistance for this issue due to this is considered to be a custom script. Again any assistance will be greatly appreciated.


Re: Script fails after upgrade from 4.x to 8.5(1)

What it's returning, the value U"\n\t\t", means a Unicode string consisting of a newline and two tabs. That so happens to be exactly what's in your XML file for the one child node in each area-code element. Here's an example from your file:

        <--- it's the stuff between here

    and here-->       

The main thing I puzzled over when looking at your script is how this was working before? Are you sure that's your original script? It might be possible to craft an XPath query to return the first node NAME below an area-code element, but I'm not sure how off the top of my head. You're almost always looking for the contents of a node. What I'd suggest you do, if possible, is use a better XML schema. Something like this:





Which can then be referenced using a simple fast XPath query like this:


The result would be what you're looking for today in your Switch statement, a simple string "MidWest" or similar. If you're absolutely married to your old XML schema, we can try to help, but do the above if you can. You might also check out the W3 Schools XPath Tutorial.