Analysis of XML base using E4X syntax

Hello

I'm going crazy with E4X parsing. I'm trying to parse an XML document that is rather simple, but I can't seem to find a way to analyze what I need.

I try to extract the name of vApps (VAPP only 1 in this example):

var xmldoc = new XML(test);
if (!xmldoc) {
  System.debug("XML PAS BON");
  var errorCode = "Invalid XML Document";
  throw "Invalid XML document";
}
System.debug("test 1 : "+xmldoc..AdminVAppRecord.@name);

It's (a response to vCloud Director REST API 5.1) XML content:

<?xml version="1.0" encoding="UTF-8"?>
<QueryResultRecords xmlns="http://www.vmware.com/vcloud/v1.5" total="1" pageSize="25" page="1" name="adminVApp" type="application/vnd.vmware.vcloud.query.idrecords+xml" href="https://myvcloudhost.com/api/admin/extension/vapps/query?page=1&pageSize=25&format=idrecords&filter=isExpired==true" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.vmware.com/vcloud/v1.5 http://myvcloudhost.com/api/v1.5/schema/master.xsd">
  <Link rel="alternate" type="application/vnd.vmware.vcloud.query.references+xml" href="https://myvcloudhost.com/api/admin/extension/vapps/query?page=1&pageSize=25&format=references&filter=isExpired==true"/>
  <Link rel="alternate" type="application/vnd.vmware.vcloud.query.records+xml" href="https://myvcloudhost.com/api/admin/extension/vapps/query?page=1&pageSize=25&format=records&filter=isExpired==true"/>
  <AdminVAppRecord vdcName="john-vdc" vdc="urn:vcloud:vdc:4cc245-23f0-439a-9b98-e85319106af1" storageKB="8388608" status="SUSPENDED" ownerName="system" org="urn:vcloud:org:19893ffe-b5de-40a6-9a08-307e41ac0f49" numberOfVMs="1" name="qsdqs" memoryAllocationMB="3072" isVdcEnabled="true" isInMaintenanceMode="false" isExpired="true" isEnabled="true" isDeployed="false" isBusy="false" creationDate="2013-08-02T15:01:39.260+02:00" cpuAllocationMhz="2" id="urn:vcloud:vapp:fe07c653-4848-4f03-a1f8-ddba8da13a50" honorBootOrder="false" pvdcHighestSupportedHardwareVersion="9" cpuAllocationInMhz="4000" taskStatus="success" lowestHardwareVersionInVApp="9" task="urn:vcloud:task:090db9f8-4b04-4550-a1a3-5396c4f25043" autoDeleteDate="2013-08-10T17:47:56.683+02:00" numberOfCpus="2" taskStatusName="vdcUpdateVapp"/>
</QueryResultRecords>

Could someone give me a hand on this one? I believe that an example of work would be enough for me to start the analysis correctly.

Thank you for your help.

A few errors here:

1. your XML file is not correct because it contains no sequence of escape '&' characters; they should be replaced by '& '.

2. your XML elements are in a namespace (see "xmlns" attribute), but your E4X query is not. You must define the namespace, for example

var vcloud = new Namespace("http://www.vmware.com/vcloud/v1.5");

and then the query will become

System.log("test 1 : " + xmldoc.vcloud::AdminVAppRecord.@name);

Hope this helps,

-Ilian

Tags: VMware

Similar Questions

  • Questions analysis XML using E4X syntax in AS 3.0

    When I try to parse the XML after using this code I get no results... However if the xml file is truncated so that organizations like node <>root. I guess the problem is the workspace names, but not sure how to fix. Any help on this is much appreciated... tried to solve this problem for 3 hours now...

    AS3.0 Code

    var xmlManifest:XML = new XML();
    xmlManifest.ignoreWhitespace = true;
    var strManifestPath:String = new String ("imsmanifest.xml");
    var urlrManifestURL:URLRequest = new URLRequest (strManifestPath);
    var urllManifestLoader:URLLoader = new URLLoader (urlrManifestURL);
    urllManifestLoader.addEventListener ("complete", manifestLoaded);

    function manifestLoaded(event:Event):void {}
    xmlManifest = XML (urllManifestLoader.data);
    xmlTitleChange (xmlManifest, "New policy");
    }
    function xmlTitleChange(xmlVar:XML,_strNewTitle:String):void {}
    trace (xmlVar.. title);
    //this returns nothing... only works trace (xmlVar).
    }

    XML document

    <? XML version = "1.0"? >
    < manifest identifier = 'reference temproary' version = "1.0".
    "xmlns ="http://www.imsproject.org/xsd/imscp_rootv1p1p2"
    "xmlns:adlcp ="http://www.adlnet.org/xsd/adlcp_rootv1p2"

    "" xmlns: xsi = "http://www.w3.org/2001/XMLSchema-instance"
    "xsi: schemaLocation ="http://www.imsproject.org/xsd/imscp_rootv1p1p2 imscp_rootv1p1p2.xsd
    http://www.imsglobal.org/XSD/imsmd_rootv1p2p1 imsmd_rootv1p2p1.xsd
    http://www.adlnet.org/XSD/adlcp_rootv1p2 adlcp_rootv1p2.xsd ">

    < default organizations = 'GENERIC TITLE' >
    < organization identifier = 'GENERIC TITLE' >
    < title > TITLE GENERIC < /title >
    < identifier = "item00" identifierref = "temproary reference" element isvisible = "true" >
    < title > TITLE GENERIC < /title >
    < adlcp:masteryscore > 70 < / adlcp:masteryscore >
    < / point >
    < metadata >
    < schema > ADL SCORM < / schema >
    < > 1.2 schemaversion < / schemaversion >
    < adlcp:location > tap.xml < / adlcp:location >
    < / metadata >
    < / organization >
    < / organizations >

    < / manifesto >

    Post edited by: Leonardo da vinci

    Use the text() method:

    function xmlTitleChange(xmlVar:XML,_strNewTitle:String):void {}
    var ns:Namespace = new Namespace (xmlVar.namespace ());
    trace (xmlVar.. NS::title. Text());
    }

  • Creation of XML file using blackberry waterfalls

    Hi all

    I use blackberry stunts to create a xml file, which will consist of data QMessage.

    The code that I am by train is as below: -.

       foreach (const Message &message, inboxMessages) {
    
        // Creating QVariant Map for each Message object
    
        QVariantMap messageMap;
        messageMap["address"] = QVariant();
        messageMap["date"]
        messageMap["subject"] = QVariant(message.subject());
        messageMap["body"] = ...........
    
        / Adding this object to Qvariant List
        QVariantList messageList= QVariantList() << QVariant(messageMap);
    
        }  // end of for each loop
    
    QVariantMap topLevelMessageMap;
    topLevelMessageMap[".root"] = QVariant("messages");
    topLevelMessageMap["message"] = QVariant(messageList);
    QVariant myData = QVariant(topLevelMessageMap);
    
    // Retrieve the working directory, and create a temporary .xml file in that
    // location
    QDir home = QDir::home();
    QTemporaryFile file(home.absoluteFilePath("myXMLFile.xml"));
    
    // Open the file that was created
    if (file.open()) {
        // Create an XmlDataAccess object and save the data to the file
        XmlDataAccess xda;
        xda.save(myData, &file);
    

    IN the above code, I create mannualy xml tags using the QVariant class.

    However is it possible where xml schema can be used from xslt/xsd and it may be analyzed to generate xml data with data to fill the Message class in accordance with the business logic.

    Please suggest

    What would you win? in my opinion this isn't a valid usecase for xslas you must complete all the values manually in any case.
    You can use xsl with qxmlquery xmldataaccess has no support in his favor.

  • I get this message: DNS server is not responding. Cannot view XML input using XSL style sheet.

    My problem was caused by using McAfee. The only way I can connect to the internet is if I start my computer in "safe mode". I've since removed McAfee from my computer, but I can't always connect to internet in normal startup mode. When I run a diagnosis, I get the message: "DNS server is not responding" & "cannot view XML input using XSL style sheet. Please correct the error and then click the Refresh button. »

    On the recommendation of MS tech support, I already tried

    1. perform a clean boot

    2. reset internet Explorer

    3 typeing these orders in the dark of the screen then restart the computer after you perform these steps

    b. Netsh int tcp reset

    c. Netsh int ipv4 reset

    zero i. (XP) netsh int ip reset

    d. Netsh winsock reset

    e. Netsh winhttp reset proxy

    f. Netsh advfirewall reset

    g. Ipconfig/flushdns

    h. Ipconfig/Release

    i. Ipconfig / renew

    j. Ipconfig/registerdns

    None of these recommendations solved my problem. I don't know if it is an IE or issue windows. Any other suggestions?

    Hello

    Please 1 create a restore point and run the mcafee Development tool. This will of cleaning after uninstalling the software. McAfee is known for questions after the uninstalled. For new AV you can try

    Microsoft Security Essentials http://windows.microsoft.com/en-us/windows/security-essentials-download. (Win08 already has Microsoft Security Essentials in the operating system)

    Tool Development

    http://service.McAfee.com/FAQDocument.aspx?ID=TS101331

    Thank you

    Thomas

  • I get an error, "cannot view XML input using XSL sheet" when I try to install a mass storage driver.

    Original title: cannot view XML input using XSL sheet

    I can't install a mass storage driver. Message "Cannot view XML input using XSL sheet".
    Unspecified error.

    Hello

    I would have you post your query in the MSDN Forums, because it is addressed to an audience of it professionals.

    Your question would be more out there.

    Check out the link-

    http://social.msdn.Microsoft.com/forums/en-us/categories/

    Back to us for any issues related to Windows in the future. We will be happy to help you.

    Thank you.

  • Cannot view XML input using XSL style sheet. Fix the error and then click the Refresh button, or try again later.

    This is the message I got when my backup stopped and said cannot complete backup. Need answers?
    Cannot view XML input using XSL style sheet. Fix the error and then click the Refresh button, or try again later.

    --------------------------------------------------------------------------------

    A name was started with an invalid character. Error during processing of the resources ' file:///E:/WindowsImageBackup/ray-PC/Backup 2011-0...

    Hi lrl1of5,

    (1) do you use Windows Backup and Restore?

    (2) if it works well before?

    (3) remember to make changes?

    It is sufficient to indicate the complete error message you receive.

    Method 1: Run the fixit available in the links below and check if that makes a difference-Worth to try
    Difficulty of broken desktop shortcuts and common system maintenance tasks

    Note: FixIt would attempt to recover bad sectors on the hard disk, in the course of this process there are chances of DATA loss from that particular area.

    Method 2:  Clean boot the computer, then try to backup again

    Follow step 1 in the link below,
    How to troubleshoot a problem by performing a clean boot in Windows Vista or in Windows 7

    Important: n ' forget not to put the computer to a normal startup follow step 7 in the link.

  • Cannot display the page XML cannot display the XML input using the XSL stylesheet

    Hi gurus of the Oracle,.

    I got this error... .once I submitted the demand shows warning... I opened exit it shows error below... I do not understand how to fix this error... Please help me... This is the CODE of PROCEDURE STORED PL/SQ L...

    The XML page cannot be displayed
    Cannot view XML input using XSL style sheet. Fix the error and then click the Refresh button, or try again later.


    --------------------------------------------------------------------------------

    A semi colon was expected. Error during processing of the resources ' http://orappsus64.tsindia.in:8009/OA_CGI/FNDWRR.exe?temp_id...

    COGNOS Quintiles/IT/J & J < CP_PROJECT > < / CP_PROJECT >
    ----------------------------^
    n-left: 1em; "text-indent:-2em" > < GL_MAIN_PERIOD > Jun-12 < / GL_MAIN_PERIOD >
    < TOTAL_REVENUE > 4026.14 < / TOTAL_REVENUE >
    < GL_PERIOD > Jun-12 < / GL_PERIOD >
    < / G_TOTAL_REVENUE_CAT >

    -------------------------------------------------------

    THIS IS MY LOG FILE
    ----------------------------------------------------------
    [01/10/12 10:44:26] [main] From service GSF with simultaneous process id is 157635.
    [01/10/12 10:44:26] [main] Initialization parameters: oracle.apps.fnd.cp.opp.OPPServiceThread:2:0:max_threads = 5
    [01/10/12 10:44:26] [Thread-22] Wire service commissioning.
    [01/10/12 10:44:26] [Thread 23] Wire service commissioning.
    [01/10/12 10:52:33] [OPPServiceThread1] Post-processing application 1296337.
    [01/10/12 10:52:33] [157635:RT1296337] The execution of the actions of post-processing for request 1296337.
    [01/10/12 10:52:34] [157635:RT1296337] From XML Publisher postprocessing action.
    [01/10/12 10:52:34] [157635:RT1296337]
    Model code: XXTGSCPR004
    Model app: PA
    Language: en
    Territory: U.S.
    Output type: EXCEL
    [100112_105234216] [] [EXCEPTION] [DEBUG] - set preferences PreferenceStore-
    [100112_105234216] [] [EXCEPTION] [DEBUG] - environment variables stored in EnvironmentStore-
    [100112_105234216] [[EXCEPTION] [DEBUG] [FND_JDBC_IDLE_THRESHOLD.] LOW]:-[1]
    [100112_105234216] [] [EXCEPTION] [DEBUG] [SECURITY_GROUP_ID]: [0]
    [100112_105234216] [] [EXCEPTION] [DEBUG] [FND_JDBC_BUFFER_DECAY_INTERVAL]: [300]
    [100112_105234217] [] [EXCEPTION] [DEBUG] [NLS_CHARACTERSET]: [US7ASCII]
    [100112_105234217] [] [EXCEPTION] [DEBUG] [RESP_APPL_ID]:-[1]
    [100112_105234217] [] [EXCEPTION] [DEBUG] [NLS_LANGUAGE]: [AMERICAN]
    [100112_105234217] [] [EXCEPTION] [DEBUG] [FND_JDBC_BUFFER_MIN]: [1]
    [100112_105234217] [] [EXCEPTION] [DEBUG] [FND_JDBC_BUFFER_MAX]: [2]
    [100112_105234217] [] [EXCEPTION] [DEBUG] [NLS_NUMERIC_CHARACTERS]: [.,]
    [100112_105234217] [] [EXCEPTION] [DEBUG] [APPS_JDBC_URL]: [jdbc:oracle:thin: @(DESCRIPTION = (ADDRESS_LIST = (LOAD_BALANCE = YES) (FAILOVER = YES) (ADDRESS = (PROTOCOL = tcp)(HOST=orappsus64.tsindia.in) (PORT = 1530))) (CONNECT_DATA = (SID = clone)))]
    [100112_105234217] [] [EXCEPTION] [DEBUG] [RESP_ID]:-[1]
    [100112_105234217] [] [EXCEPTION] [DEBUG] [FND_MAX_JDBC_CONNECTIONS]: [500]
    [100112_105234217] [] [EXCEPTION] [DEBUG] [FND_JDBC_USABLE_CHECK]: [false]
    [100112_105234218] [] [EXCEPTION] [DEBUG] [USER_ID]:-[1]
    [100112_105234218] [] [EXCEPTION] [DEBUG] [NLS_TERRITORY]: [AMERICA]
    [100112_105234218] [] [EXCEPTION] [DEBUG] [FND_JDBC_PLSQL_RESET]: [false]
    [100112_105234218] [] [EXCEPTION] [DEBUG] [FND_JDBC_CONTEXT_CHECK]: [true]
    [100112_105234218] [] [EXCEPTION] [DEBUG] [NLS_DATE_FORMAT]: [DD-MON-RR]
    [100112_105234218] [] [EXCEPTION] [DEBUG] [FND_JDBC_BUFFER_DECAY_SIZE]: [5]
    [100112_105234218] [[EXCEPTION] [DEBUG] [FND_JDBC_IDLE_THRESHOLD.] HIGH]:-[1]
    [100112_105234218] [] [EXCEPTION] [DEBUG] [NLS_SORT]: [BINARY]
    [100112_105234218] [] [EXCEPTION] [DEBUG] [NLS_DATE_LANGUAGE]: [AMERICAN]
    [100112_105234218] [] [EXCEPTION] [DEBUG] [LOGIN_ID]:-[1]
    [100112_105234218] [] [EXCEPTION] [DEBUG] - properties stored in the Java System Properties-
    [100112_105234219] [] [EXCEPTION] [DEBUG] [APPLTMP]: [AP1/oracle/PROD01/inst/apps/clone_orappsus64/appltmp]
    [100112_105234219] [] [EXCEPTION] [DEBUG] [java.runtime.name]: [Java (TM) SE Runtime Environment]
    [100112_105234219] [EXCEPTION] [DEBUG] [sun.boot.library.path]:[AP1/oracle/PROD01/apps/tech_st/10.1.3/appsutil/jdk/jre/lib/i386]]
    [100112_105234219] [] [EXCEPTION] [DEBUG] [java.vm.version]: [11: 0 - b15]
    [100112_105234219] [] [EXCEPTION] [DEBUG] [OVERRIDE_DBC]: [true]
    [100112_105234219] [EXCEPTION] [DEBUG] [dbcfile]:[AP1/oracle/PROD01/inst/apps/clone_orappsus64/appl/fnd/12.0.0/secure/clone.dbc]]
    [100112_105234219] [] [EXCEPTION] [DEBUG] [java.vm.vendor]: [Sun Microsystems Inc..]
    [100112_105234219] [] [EXCEPTION] [DEBUG] [java.vendor.url]: [http://java.sun.com/]
    [100112_105234219] [[EXCEPTION] [DEBUG] [path.separator]]: [[:]
    [100112_105234219] [] [EXCEPTION] [DEBUG] [APPLCSF]: [AP1/oracle/PROD01/inst/apps/clone_orappsus64/papers/appl/conc]
    [100112_105234220] [] [EXCEPTION] [DEBUG] [java.vm.name]: [the server VM Java]
    [100112_105234220] [] [EXCEPTION] [DEBUG] [file.encoding.pkg]: [sun.io]
    [100112_105234220] [] [EXCEPTION] [DEBUG] [sun.java.launcher]: [SUN_STANDARD]
    [100112_105234220] [] [EXCEPTION] [DEBUG] [user.country]: [US]
    [100112_105234220] [] [EXCEPTION] [DEBUG] [sun.os.patch.level]: [unknown]
    [100112_105234220] [] [EXCEPTION] [DEBUG] [java.vm.specification.name]: [Java Virtual Machine specifications]
    [100112_105234220] [EXCEPTION] [DEBUG] [user.dir]:[AP1/oracle/PROD01/inst/apps/clone_orappsus64/logs/appl/conc/log]]
    [100112_105234220] [] [EXCEPTION] [DEBUG] [java.runtime.version]: [1.6.0_10 - b33]
    [100112_105234220] [] [EXCEPTION] [DEBUG] [CLIENT_PROCESSID]: [25943]
    [100112_105234220] [] [EXCEPTION] [DEBUG] [java.awt.graphicsenv]: [sun.awt.X11GraphicsEnvironment]
    [100112_105234220] [EXCEPTION] [DEBUG] [java.endorsed.dirs]:[AP1/oracle/PROD01/apps/tech_st/10.1.3/appsutil/jdk/jre/lib/endorsed]]
    [100112_105234221] [] [EXCEPTION] [DEBUG] [os.arch]: [i386]
    [100112_105234221] [EXCEPTION] [DEBUG] [JTFDBCFILE]:[AP1/oracle/PROD01/inst/apps/clone_orappsus64/appl/fnd/12.0.0/secure/clone.dbc]]
    [100112_105234221] [] [EXCEPTION] [DEBUG] [java.io.tmpdir]: [tmp]
    [100112_105234221] [] [EXCEPTION] [DEBUG] [line.separator]:]
    ]
    [100112_105234221] [] [EXCEPTION] [DEBUG] [java.vm.specification.vendor]: [Sun Microsystems Inc..]
    [100112_105234221] [] [EXCEPTION] [DEBUG] [os.name]: [Linux]
    [100112_105234221] [] [EXCEPTION] [DEBUG] [FND_JDBC_BUFFER_MIN]: [1]
    [100112_105234221] [] [EXCEPTION] [DEBUG] [CPID]: [157635]
    [100112_105234221] [] [EXCEPTION] [DEBUG] [sun.jnu.encoding]: [UTF-8]
    [100112_105234221] [] [EXCEPTION] [DEBUG] [oracle.apps.fnd.common.Pool.leak.mode]: [stderr: off]
    [100112_105234221] [][EXCEPTION] [DEBUG] [java.library.path]:[AP1/oracle/PROD01/apps/tech_st/10.1.3/appsutil/jdk/jre/lib/i386/server:/AP1/oracle/PROD01/apps/tech_st/10.1.3/appsutil/jdk/jre/lib/i386:/AP1/oracle/PROD01/apps/tech_st/10.1.3/appsutil/jdk/jre/.. /lib/i386:/AP1/oracle/PROD01/apps/tech_st/10.1.3/lib32:/AP1/oracle/PROD01/apps/tech_st/10.1.3/lib:/AP1/oracle/PROD01/apps/apps_st/appl/cz/12.0.0/bin:/AP1/oracle/PROD01/apps/apps_st/appl/iby/12.0.0/bin:/AP1/oracle/PROD01/apps/ apps_st/appl/PON/12.0.0/bin:/ap1/Oracle/PROD01/apps/apps_st/appl/SHT/12.0.0/lib:/usr/java/packages/lib/i386:/lib:/usr/lib]
    [100112_105234222] [] [EXCEPTION] [DEBUG] [java.specification.name]: [Java platform API specification]
    [100112_105234222] [] [EXCEPTION] [DEBUG] [java.class.version]: [50.0]
    [100112_105234222] [] [EXCEPTION] [DEBUG] [sun.management.compiler]: [HotSpot Tiered compilers]
    [100112_105234222] [] [EXCEPTION] [DEBUG] [queue_appl_id]: [0]
    [100112_105234222] [] [EXCEPTION] [DEBUG] [os.version]: [2.6.18 - 128.el5]
    [100112_105234222] [] [EXCEPTION] [DEBUG] [LONG_RUNNING_JVM]: [true]
    [100112_105234222] [] [EXCEPTION] [DEBUG] [user.home]: [home/applmgr01]
    [100112_105234222] [] [EXCEPTION] [DEBUG] [user.timezone]: [Asia/Kolkata]
    [100112_105234222] [] [EXCEPTION] [DEBUG] [java.awt.printerjob]: [sun.print.PSPrinterJob]
    [100112_105234222] [] [EXCEPTION] [DEBUG] [file.encoding]: [UTF-8]
    [100112_105234222] [] [EXCEPTION] [DEBUG] [java.specification.version]: [1.6]
    [100112_105234222] [] [EXCEPTION] [DEBUG] [CACHEMODE]: [PUBLISHED]
    [100112_105234222] [] [EXCEPTION] [DEBUG] [conc_queue_id]: [6269]
    [100112_105234222] [][EXCEPTION] [DEBUG] [java.class.path]:[AP1/oracle/PROD01/apps/tech_st/10.1.3/appsutil/jdk/lib/dt.jar:/AP1/oracle/PROD01/apps/tech_st/10.1.3/appsutil/jdk/lib/tools.jar:/AP1/oracle/PROD01/apps/tech_st/10.1.3/appsutil/jdk/jre/lib/rt.jar:/AP1/oracle/PROD01/apps/apps_st/comn/java/lib/appsborg2.zip:/AP1/oracle/PROD01/apps/apps_st/comn/java/classes]
    [100112_105234222] [] [EXCEPTION] [DEBUG] [user.name]: [applmgr01]
    [100112_105234222] [EXCEPTION] [DEBUG] [DBCFILE]:[AP1/oracle/PROD01/inst/apps/clone_orappsus64/appl/fnd/12.0.0/secure/clone.dbc]]
    [100112_105234222] [] [EXCEPTION] [DEBUG] [java.vm.specification.version]: [1.0]
    [100112_105234222] [EXCEPTION] [DEBUG] [java.home]:[AP1/oracle/PROD01/apps/tech_st/10.1.3/appsutil/jdk/jre]]
    [100112_105234222] [] [EXCEPTION] [DEBUG] [sun.arch.data.model]: [32]
    [100112_105234223] [] [EXCEPTION] [DEBUG] [user.language]: [in]
    [100112_105234223] [] [EXCEPTION] [DEBUG] [java.specification.vendor]: [Sun Microsystems Inc..]
    [100112_105234223] [] [EXCEPTION] [DEBUG] [mode java.vm.info]: [mixed]
    [100112_105234223] [EXCEPTION] [DEBUG] [logfile]:[AP1/oracle/PROD01/inst/apps/clone_orappsus64/logs/appl/conc/log/FNDOPP157635.txt]]
    [100112_105234223] [] [EXCEPTION] [DEBUG] [java.version]: [1.6.0_10]
    [100112_105234223] [] [EXCEPTION] [DEBUG] [JAVA. EXT. DIRS]:[AP1/ORACLE/PROD01/APPS/TECH_ST/10.1.3/APPSUTIL/JDK/JRE/LIB/EXT:/USR/JAVA/PACKAGES/LIB/EXT]
    [100112_105234223] [][EXCEPTION] [DEBUG] [sun.boot.class.path]:[AP1/oracle/PROD01/apps/tech_st/10.1.3/appsutil/jdk/jre/lib/resources.jar:/AP1/oracle/PROD01/apps/tech_st/10.1.3/appsutil/jdk/jre/lib/rt.jar:/AP1/oracle/PROD01/apps/tech_st/10.1.3/appsutil/jdk/jre/lib/sunrsasign.jar:/AP1/oracle/PROD01/apps/tech_st/10.1.3/appsutil/jdk/jre/lib/jsse.jar:/AP1/oracle/PROD01/apps/tech_st/10.1.3/appsutil/jdk/jre/lib/jce.jar:/AP1/oracle/PROD01/apps/tech_st/10.1.3/appsutil/jdk/jre/lib/charsets.jar:/AP1/oracle/PROD01/apps/tech_ St/10.1.3/appsutil/JDK/JRE/classes]
    [100112_105234223] [] [EXCEPTION] [DEBUG] [java.vendor]: [Sun Microsystems Inc..]
    [100112_105234223] [] [EXCEPTION] [DEBUG] [FND_JDBC_BUFFER_MAX]: [2]
    [100112_105234223] [] [EXCEPTION] [DEBUG] [file.separator]:]
    [100112_105234223] [] [EXCEPTION] [DEBUG] [java.vendor.url.bug]: [http://java.sun.com/cgi-bin/bugreport.cgi]
    [100112_105234223] [] [EXCEPTION] [DEBUG] [sun.io.unicode.encoding]: [UnicodeLittle]
    [100112_105234223] [] [EXCEPTION] [DEBUG] [sun.cpu.endian]: [little]
    [100112_105234223] [] [EXCEPTION] [DEBUG] [APPLOUT]: [out]
    [100112_105234223] [] [EXCEPTION] [DEBUG] [sun.cpu.isalist]:]
    [01/10/12 10:52:35] [UNEXPECTED] [157635:RT1296337] java.lang.reflect.InvocationTargetException
    at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:597)
    at oracle.apps.xdo.common.xml.XSLT10gR1.invokeParse(XSLT10gR1.java:517)
    at oracle.apps.xdo.common.xml.XSLT10gR1.transform(XSLT10gR1.java:224)
    at oracle.apps.xdo.common.xml.XSLTWrapper.transform(XSLTWrapper.java:177)
    at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:1044)
    at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:997)
    at oracle.apps.xdo.template.fo.util.FOUtility.generateFO(FOUtility.java:212)
    at oracle.apps.xdo.template.FOProcessor.createFO(FOProcessor.java:1665)
    at oracle.apps.xdo.template.FOProcessor.generate(FOProcessor.java:975)
    at oracle.apps.xdo.oa.schema.server.TemplateHelper.runProcessTemplate(TemplateHelper.java:5936)
    at oracle.apps.xdo.oa.schema.server.TemplateHelper.processTemplate(TemplateHelper.java:3459)
    at oracle.apps.xdo.oa.schema.server.TemplateHelper.processTemplate(TemplateHelper.java:3548)
    at oracle.apps.fnd.cp.opp.XMLPublisherProcessor.process(XMLPublisherProcessor.java:285)
    at oracle.apps.fnd.cp.opp.OPPRequestThread.run(OPPRequestThread.java:173)
    Caused by: oracle.xdo.parser.v2.XMLParseException: expected '; '.
    at oracle.xdo.parser.v2.XMLError.flushErrors1(XMLError.java:337)
    at oracle.xdo.parser.v2.NonValidatingParser.parseDocument(NonValidatingParser.java:305)
    at oracle.xdo.parser.v2.XMLParser.parse(XMLParser.java:289)
    ... more than 17

    [01/10/12 10:52:35] [157635:RT1296337] Over the actions of post-processing to request 1296337.
    [GC 8059K - > 6286K (8692K), dry 0,0076290]
    [Full GC [unloading class sun.reflect.GeneratedSerializationConstructorAccessor17]]
    [Unloading class sun.reflect.GeneratedSerializationConstructorAccessor19]
    [Unloading class sun.reflect.GeneratedSerializationConstructorAccessor18]
    [Unloading class sun.reflect.GeneratedSerializationConstructorAccessor13]
    6286 K - > 3865 K (8692 K), dry 0,0446370]

    Please help big appriciation.

    Thank you

    Siddarth.

    OK, the solution is quite "simple" then.
    Each string that can contain XML reserved characters must be escaped before concatenating XML tags.

    I see that the code has already some replace(column_name, '&', ''), perhaps that was added in the same goal, but a bad solution.

    A better solution would be to use the SQL/XML functions, but it would mean that the refactoring cursors.
    Therefore, an intermediate solution (if you want to keep '&' characters in the output) is to escape the chain properly.

    For example, in the GET_PROJECTS cursor:

    CURSOR get_projects ( p_customer_id            IN    NUMBER
                        , p_bu_vertical            IN    VARCHAR2
                        , p_line_of_business    IN    VARCHAR2
                       -- , p_period_set_name        IN    VARCHAR2
                        , p_gl_period_from        IN    VARCHAR2
                        , p_gl_period_to        IN    VARCHAR2
                        , p_project_id_FROM        IN    NUMBER
                        , p_project_id_to        IN    NUMBER
                        , p_organization_name  IN    VARCHAR2
                        ) IS
    SELECT DISTINCT   replace(pa.name, '&','') project_name
         ,pa.project_id
         , utl_i18n.escape_reference(pa.segment1) as project_number   --< Here
         , pa.project_currency_code
         , hp.party_id
    ...
    

    This should solve the problem with the CP_PROJECT tag.
    Repeat on the other columns if necessary.

  • Error when loading an XML document using a structured application

    Hello

    I try to load an XML document using a structured application defined in the default structapps.fm

    My code is shown, extracted from the sample code API FDK.

    Problem, I still got the same message:

    "Cannot find the file named e:\xml\AdobeFrameMaker10\file. Make sure that the file exists. "

    Where "e:\xml\AdobeFrameMaker10\" is my installation directory.

    So I guess that govern trying to find the structapps.fm file but can't find it.

    What else can we?

    Does anyone known how elements achieve this simple task using extendScript?

    Thanks for all comments, Pierre

    function openXMLFile (myLastFile) {}

    var filename = myLastFile.openDlg ("XML file choose...", "*.xml", false);

    If (filename! = null) {}

    / * Default Get open the properties. Back so it can not be affected. */

    var params = GetOpenDefaultParams();

    / * Set properties to open an XML document * /.

    / * Specify XML as the type of file to open * /.

    var i = GetPropIndex (params, Constants.FS_OpenAsType)

    params [i].propVal.ival = Constants.FV_TYPE_XML;

    / * Specify the XML application to use when opening the text.

    I have = GetPropIndex (params, Constants.FS_StructuredOpenApplication)

    params [i].propVal.sval = "myApp";

    I have = GetPropIndex (params, Constants.FS_FileIsOldVersion)

    params [i].propVal.ival = Constants.FV_DoOK

    I have = GetPropIndex (params, Constants.FS_FontNotFoundInDoc)

    params [i].propVal.ival = Constants.FV_DoOK

    I have = GetPropIndex (params, Constants.FS_FileIsInUse)

    params [i].propVal.ival = Constants.FV_DoCancel

    I have = GetPropIndex (params, Constants.FS_AlertUserAboutFailure)

    params [i].propVal.ival = Constants.FV_DoCancel

    / * The file structapps.fm that contains the specified app must have

    already been read. The default structapps.fm file is read when FrameMaker is

    open so this shouldn't be a problem if the application to use is

    listed in the structapps.fm fichier.*.

    var retParm = new PropVals()

    var fileObj = Open (filename, params, retParm);

    return fileObj

    } else {}

    Returns a null value.

    }

    }

    Stone,

    According to the "myLastFile" object, the method openDlg may not yet exist (if the myLastFile object is not an object file, for example). And I do not see the myLastFile be necessary anyway, you present a dialog box to select a file to open. I recommend to use the global method of ChooseFile () instead. This will give you a file name as string in the notation of full path, or null if no file has been selected in the dialog box. I'm not sure of what your States of the return value for ChooseFile ExtendScript documentation, but if that differs from what I tell you here, won't the documentation. For example, if you change the first lines of your code by the following it should work:

    function () {} openXMLFile

    var filename = ChooseFile ('choose XML file... ("," ","*.xml", Constants.FV_ChooseSelect);

    While writing this, I see that Russ already gave you the same advice. Use the value of symbolic constant, I stated to use the ChooseFile dialog box to select a single file (it can also be used to select a directory or open a file - but you want control you the logon process). Note that this method allows you to define a directory for the dialog (second parameter). The ESTK autocompletion also gives you a fifth parameter "helplink" who is undocumented and may be ignored.

    Good luck

    Jang

  • Analysis of XML, how to get a specific tag?

    Hello

    I'm new to Flex, attempts to load data from the xml file using httpservice. all right, but I don't know how to access a specific tag.

    xml mapping is shown in the image:

    imageforum.JPG

    I'm trying to access DEVICE1, dataService.Lastresult.trames.tramdevices [?] something like that. Sombody knows how? Thank you very much. I used xml with java but in flex is a little different. Thank you very much for all.

    Hi neoto,.

    Have you tried ... dataService.Lastresult.trames.tramdevices.Device1?

    Thank you

    Jean Claude

  • My native BB app, how to connect to the remote URL and call a Web service method to retrieve the XML base result using Eclipse Version 3.7.2

    Hello

    I am new to the development of native applications from BB using JDE. I'm testing Simulator. From my native BB app, I connect a remote URL and call a Web service method to extract some basic result XML.

    I need to write a login code remote URL to achieve? If so, how?

    So, how can I use this connection object to call the Web service from this URL remotely.

    Please help me out of it...

    Many thanks in advance...

    What i am doing is, On clicking the "Login" button i want to call the webservice method like below mentioned code...
    Here WaveServices is a class and getAllCinemas() is a static method inside which a webservice method call is made..
    
    loginButtonField.setChangeListener(new FieldChangeListener() {
                public void fieldChanged(Field paramField, int paramInt) {
                    WaveServices.getAllCinemas();
                }
            });
    

    Indeed, the question was raised and answered here:

    http://supportforums.BlackBerry.com/T5/Java-development/from-my-native-BB-application-how-to-connect...

  • Analysis of XML files

    I have a problem, the analysis of this XML file. I swear it worked but now the sections DC_Source and DC_Load return null.

    In XML (Subvi) .vi tag monitor, look at the results on the terminal. The wire that connects to the Terminal should use a shift register.

  • Analysis of xml with QT

    Hello

    Is there a way to parse the XML in a QString? All of the examples on the web shows how to parse the XML for the file, but none of them shows how to parse XML from a QString. I have a server for my app to connect to via TCP/IP, and the server then sends the XML to the client (app) to be scanned, it will be a waste of resources prior to writing the XML to a file.

    I have the base sax parser and my implementation looks like this

    XMLHandler * m_handler;

    QXmlInputSource * source = new QXmlInputSource (new QFile("asset:///responseMessage.xml"));)

    QXmlSimpleReader reader;
    reader.setContentHandler (m_handler);

    Reader.Parse (source);

    How can I change this line

    QXmlInputSource * source = new QXmlInputSource (new QFile("asset:///responseMessage.xml"));)

    to use a string input, and not a file? I know that QXmlInputSource class does not support a string of implementation is if there is another approach in the API that I can use?

    Thank you for all the advice!

    I found the solution. I changed my class instead to use a QXmlStreamReader. It can take values QByteArray in its constructor so I just called the QString toAscii method to convert the string received from my server to a QByteArray and passed to the QXmlStreamReader. This implementation does not require major changes to my manager so I think it works best for my situation. Thanks for all the help guys.

  • Analysis sax XML parser

    Hello...

    I would like to publish this example to help pasring xml or live feed from a URL.

    SAXParserFactory plant = SAXParserFactory.newInstance ();
    SAXParser saxParser = factory.newSAXParser ();

    DefaultHandler Manager = new DefaultHandler() {}

    ' public void startElement (String uri, String localName, String qName,
    Attributes attributes) throws SAXException {}
    If (qName.equalsIgnoreCase ("an element of xml"))
    {

    vector.addElement (attributes.getValue ("attribute of an element"));

    }

    ElseIf (qName.equalsIgnoreCase ("second item FRO xml"))
    {

    attributteValue = attributes.getValue ("title");

    }

    ' public void endElement (String uri, String localName, String qName)
    throws SAXException {}

    currentElement = false;

    If (qName.equalsIgnoreCase ("end of the element"))
    {
    do something
    }

    }

    };
    S StreamConnection = null;

    s = (StreamConnection) Connector.open ("enter the url that provides the xml file");
    HttpConnection httpConn s = (HttpConnection);

    If (httpConn.getResponseCode () is 400)

    {
    Dialog.Alert ("internett noaccess");

    }

    InputStream input = null;
    entry = s.openInputStream ();

    Reader reader = new InputStreamReader(input,"UTF-8");
    InputSource is = new InputSource (reader);
    is.setEncoding("UTF-8");

    saxParser.parse (, Manager);
    }

    Add the required elements of the XML in the analysis to the vectors and do something.

    SAX (Simple API for XML) is a parser based on the events in sequential access API developed by the XML - DEV list for XML documents. SAX provides a mechanism for reading data from an XML document that is an alternative to that provided by the DOM (Document Object). When the DOM works on the document as a whole, SAX parsers function on each element of the XML document in order.

    SAX parsers have certain advantages over DOM-style parsers. A SAX parser doesn't need to declare every event analysis what happens and almost all of these once-reported information normally rejects (he does, however, keep some things, for example a list of all the elements that have not been closed yet, in order to intercept errors later as the end tags in the wrong order). Thus, the minimum memory required for a SAX parser is proportional to the maximum depth of the XML (i.e. the XML tree) and the maximum data involved in a single XML event (for example, the name and the attributes of a single tag start, or the content of a processing instruction, etc.).

    This amount of memory is generally regarded as negligible. A DOM parser, however, usually built a representation of the tree of the entire document in memory at first, using memory that increases with the length of the entire document. It takes a lot of time and space for large documents (memory allocation and the construction of data structures take time). The advantage of compensation, of course, is that once loaded no matter what part of the document are accessible in any order.

    I hope this post was helpful.



    Welcome on the support forums.

    Thank you for contributing. There is however a minor problem: all blocking operations must be made on a separate thread. You cannot use Dialog.alert on a thread without use invokelater or synchronization on the eventlock, you should fix that.

    In addition, there are a lot of response codes, and you should check for 200 continue, otherwise trigger an error.

    There is also a xmldemo in the samples provided with the eclipse plugin or JDE, but it uses DocumentBuilder, no Sax.

  • Analysis of XML with SAX parser

    
    
    
      
         
        
                
        
                
            
        
        
                
        
                
            
    
    
        
                
    
        
                
          
    
    
        
                
    
        
                        
    
            
                
    
        
                
        
                
    
        
                
        
    
    
    

    It comes to my XML. I am able to analyze using the DOM parser, bt I m new analysis SAX. Can someone help me to analyze it using SAX parser

    There is a snippet of Code to call the HTTP Xml & only to the analyzed using Sax parser.

    SAXParserImpl saxparser = new SAXParserImpl();
    ListParser receivedListHandler=new  ListParser();
    static DataInputStream din = null;
    public static String response;
    
        HttpConnection hc = null;
            OutputStream os;
               try
               {
                   final String url =""+ InitClass.getConnectionString()+";ConnectionTimeout=25000";
    
                   hc = (HttpConnection)Connector.open(url);
    
                   os = hc.openOutputStream();
                   os.write(postDataBytes);
    
                   if (hc.getResponseCode() == 200)
                        din = hc.openDataInputStream();
                    else
                        response = "" + hc.getResponseCode();
                    saxparser.parse(din, receivedListHandler);
               }
               catch (Exception e)
               {
    
               }
               finally
               {
                  try
                  {
                      if(din!=null)
                          din.close();
                      din = null;
                      if(hc!=null)
                          hc.close();
                      hc = null;
                  }
                  catch (Exception e) {   }
               }
    

    class Analyzer

    public class ListParser extends DefaultHandler
    {
    private String Key="";
    private  Hashtable ht=new Hashtable();
    vector vec = new Vector();
    public ListParser()
    {
    
    }
    /**
    * Gets called, whenever a Xml is start .
    */
    public void startDocument() throws SAXException
    {
    
    }
    /**
    * Gets called, whenever a Xml is End .
    */
    public void endDocument() throws SAXException
    { 
    
    }
    /**
    * Gets called, whenever a new tag is found.
    */
    public void startElement(String uri, String localName, String name, Attributes attributes) throws SAXException
    {
        if(name.equals(""))
        {
            ht = null;
            ht = new Hashtable();
        }
        else if(name.equals(""))
        {
    
        }
        Key=name;
    }
    
    /**
    * Gets called, whenever a closed tag is found.
    */
    public void endElement(String uri, String localName, String name) throws SAXException
    {
        if(name.equals(""))
        {
            vec.addElement(ht);
        }
    }
    public void characters(char[] ch, int start, int length) throws SAXException
    {
        String element=new String(ch, start, length);
        ht.put(Key, element);
    }
    }
    

    It will analyze your XML file and you will get data of vector vec in hash tables by XML tag.

  • ListView xml by using the data source does not?

    Hello

    When I use the data for loading XML source, listview displays data only if there is at least 2 element in the XML file.

    import bb.cascades 1.0
    import bb.data 1.0
    NavigationPane {
        id: nav
        Page {
    
            id: emp
            titleBar: TitleBar {
                visibility: ChromeVisibility.Visible
            }
            onCreationCompleted:
                                    {
                                        dataSource1.load(); //load the xml when page is created
                                    }
            actions: [
    
                ActionItem {
                    title: qsTr("Create List")
                    ActionBar.placement: ActionBarPlacement.OnBar
                    onTriggered: {
                        dialog.open();
                    }
                }
            ]
            Container {
                topPadding: 30.0
                leftPadding: 20.0
                rightPadding: 20.0
    
              ListView {
                  id:list1
                dataModel:dataModel
                 listItemComponents: [
                            ListItemComponent {
    
                                StandardListItem {
    
                                     title: {
                                    qsTr(ListItemData.name)
                                }
                                }
                            }
                        ]
    
                }
    
            }
    
                 } //page
    
        attachedObjects: [
             GroupDataModel {
                        id:dataModel
                    },
                     DataSource {
                          id: dataSource1
                          source: "models/employeelist.xml"
                         query: "/root/employee"
                        type: DataSourceType.Xml
                          onDataLoaded: {
                          dataModel.clear();
                           dataModel.insertList(data);
                          }
                        },
            Dialog {
                id: dialog
                Container {
                    background: Color.Gray
                    layout: StackLayout {
                    }
                    verticalAlignment: VerticalAlignment.Center
                    horizontalAlignment: HorizontalAlignment.Center
                    preferredWidth: 700.0
                    leftPadding: 20.0
                    rightPadding: 20.0
                    topPadding: 20.0
                    bottomPadding: 20.0
                    Container {
                        background: Color.White
                        horizontalAlignment: HorizontalAlignment.Center
                        preferredWidth: 700.0
                        preferredHeight: 50.0
                        Label {
                            text: "Add Employee List"
                            textStyle.base: SystemDefaults.TextStyles.TitleText
                            textStyle.color: Color.DarkBlue
                            horizontalAlignment: HorizontalAlignment.Center
                            textStyle.fontSizeValue: 4.0
                        }
                    }
                    Container
                    {
                        topPadding: 30.0
                        layout: StackLayout {
                            orientation: LayoutOrientation.LeftToRight
                        }
                        Label {
                        text: "Employee Name "
                    }
                    TextField {
                        id:nametxt
                    }
                }
               Container {
                   topPadding: 30.0
                        layout: StackLayout {
                            orientation: LayoutOrientation.LeftToRight
                        }
                        Button {
                           text: "OK"
                   onClicked:
                       {
                   var name=nametxt.text;
                   if(nametxt.text=="")
                   {
                        _model.toastinQml("Please enter a name");
                   }
                   else
                   {
    
                       _model.writeEmployeeName(name); //writing name to the employeelist.xml
    
                       nametxt.text="";
                       dialog.close();
                     dataSource1.load(); //loading the xml
                     }
    
                       }
                            preferredWidth: 300.0
                        }
                Button {
                     text: "Cancel"
                     onClicked:
                         {
                             dialog.close();
                         }
                            preferredWidth: 300.0
                        }
                             }
                }
            }
        ]
    
    }//navigation
    

    When I add a name to the first time to the XML, the list shows nothing. Then, when I add a new name, it displays the list.

    Why is it so? Is there a any mistake I made?

    Help, please!

    Thanks in advance

    Diakite

    It seems that there is a problem reported on the DIT that was refitted with internal BlackBerry MKS defect tracking system. Until this issue is reviewed by our internal teams, please use the solution suggested by the Rapporteur for the question by introducing an "if" statement before inserting data to the DataModel:

                    if (data.name) {
                        empDataModel.insert(data);
                    } else {
                        empDataModel.insertList(data);
                    }
    

Maybe you are looking for

  • Need a wall bracket for 40RV700A / 40CV700A

    My son has this TV; It seems the way in which the guarantee is made, only a certified Toshiba wall can be mounted to the television, but Toshiba do not all wall list approved for this model, which leaves us stuck.

  • Multiple Ukraine power measurement

    Hello I use the card Ni SMU 4143. I have a VI that propels a certain voltage level card.  Now, I'm trying to create a separate VI which will only measure the voltage and current on the power supply without a reset provision. I understand that I must

  • paper mismatch

    I have a HP Officejet 6500 printer.  The printer worked pretty well since I bought it.  However, now I am having a problem.  I tried to clean the print heads using 6 (Tools) and 2 (clean print heads) options for the printer.  The printer started to c

  • Read audio streaming...

    Hi all I want to play the song streaming. I want to play the audio file. But instead of the connection with the specific file. I want to skip the array of bytes to the stream and then play these bytes to the players. How can I achieve this?

  • Photoes Smartphones blackBerry problem

    Hi long since I bought the BB Curve 3 G I was faced this problem. When I click on the photos she is saved, but you don't see them in the photo folder when you want to view. However, you can send these images via whatsapp immediately and these photos