Help with XQueriyng an AWS XML file

--Oracle Database 11g Express Edition Release 11.2.0.2.0 - Beta
I am trying to query an XML file returned from Amazon AWS. I'm learning this slowly, and i think examples would really help . I'm reading and looking through the documentation " [Using XQuery with Oracle XML DB|http://docs.oracle.com/cd/E11882_01/appdev.112/e23094/xdb_xquery.htm] ".
I made an batch of 2 ItemLookup requests to AWS, which returned one item for the first lookup, and two for the second, which i think is a good example. I used a bogus account id (it's used for tracking) and a key pair which i deleted after using it, so it is the actual reply. It is too large to be passed as a literal, so i put it on pastebin. It shows a valid request. There are two levels of validity, one is no error, the other IsValid. Had there been an error, like a missing parameter, the following would be between the </Arguments> and <RequestProcessingTime> tags:
    <Errors>
      <Error>
        <Code>AWS.MissingParameters</Code>
        <Message>Your request is missing required parameters. Required parameters include ItemId.</Message>
      </Error>
    </Errors>Meaning, first the XML document must be checked for the Errors tag; second, the IsValid element must be True; third, actual data can be perused. The Errors tag mean there may be multiple errors. The IsValid is per Items (not Item). Then individual details may be grabbed, such as ListPrice.
I'm guessing XQuery is the right way to go here, using XMLTABLE to create records to be queried. Here is what i have so far:
SELECT
FROM
     XMLTABLE
      XMLNAMESPACES(DEFAULT 'http://webservices.amazon.com/AWSECommerceService/2011-08-01'),
      '/ItemLookupResponse/OperationRequest/Errors/Error,
     for $Error in /ItemLookupResponse/OperationRequest/Errors/Error
       return
          <Error>
           $Error/Code,
           $Error/Message
          </Error>,
      for $Item in /ItemLookupResponse/Items
       return
          <Item>
           $Item/Request/IsValid
          </Item>'
      PASSING
          (code to get XML document: e.g. ItemLookup('036500101794', 'UPC', 'OfficeProducts', '5011363525517', 'EAN', 'Toys'))
      COLUMNS
          Id FOR ORDINALITY,
          Error_Code     VARCHAR2(10) PATH 'Code',
          Error_Message     VARCHAR2(10) PATH 'Message',
          IsValid          VARCHAR2(05) PATH 'IsValid'
     );Of which the response is:
        ID ERROR_CODE ERROR_MESS ISVAL
         1                       True
         2                       TrueOstensibly, there are no errors, so the first record is the IsValid element for the first Items tag, and the second for the second. Now, i need to loop inside each Items for all of its Item tags.
1) Is this a good approach. I ask because this is really my first XQuery.
2) Is the for loop for Errors good? I am assuming it will only have a record if there is an error.
3) Do i nest for loops to get each Item in each Items?
4) How do i know which Items is being used when in the (sub) Item tag?
I would appreciate any help. It just hasn't "clicked" yet, and i am having a hard time knowing what to do.

OK, figured it out....The XMLTABLE does the join, so the FULL JOIN is simply not required:
Making the final code:
     WITH
          XML(Document)
     AS
           SELECT
               Amazon_PAPI.Get_Response(Amazon_PAPI.ItemLookup('036500101794', 'UPC', 'OfficeProducts', '5011363525517', 'EAN', 'Toys'))
           FROM
               Dual
     SELECT
          Items.Id,
          Items.Code,
          Items.Message,
          Items.Isvalid,
          Item.Id Item_Id,
          Item.ASIN
     FROM
          XMLTABLE
           XMLNAMESPACES(DEFAULT 'http://webservices.amazon.com/AWSECommerceService/2011-08-01'),
           '/ItemLookupResponse/OperationRequest/Errors/Error
           | /ItemLookupResponse/Items'
           PASSING
               (SELECT Document FROM XML)
           COLUMNS
                Id          FOR ORDINALITY,
               Code          VARCHAR2(0050)     PATH 'Code',
               Message          VARCHAR2(4000)     PATH 'Message',
               IsValid          VARCHAR2(005)     PATH 'Request/IsValid',
               Item          XMLTYPE          PATH 'Item'
          ) Items
     LEFT JOIN
          XMLTABLE
           XMLNAMESPACES(DEFAULT 'http://webservices.amazon.com/AWSECommerceService/2011-08-01'),
           '/Item'
           PASSING
               Items.Item
           COLUMNS
               Id                    FOR ORDINALITY,
               ASIN                    VARCHAR2(0010)     PATH 'ASIN'
          ) Item
      ON
          1 = 1
     ORDER BY
          Items.Id,
          Item.Id;With the result, when successful:
        ID CODE                                     MESSAGE                                            ISVAL    ITEM_ID ASIN
         1                                                                                             True       1 B004WL0L9S
         2                                                                                             True       1 B0042ET8OO
         2                                                                                             True       2 B00004TQMQAnd when not successful:
        ID CODE                                     MESSAGE                                            ISVAL    ITEM_ID ASIN
         1 AWS.InvalidEnumeratedParameter           The value you specified for IdType is invalid.
                                                    Valid values include ['ASIN', 'SKU',
                                                    'UPC', 'EAN','ISBN'].
         2 AWS.RestrictedParameterValueCombination  Your request contained a restricted parameter
                                                    combination.  When IdType equals UPCa, SearchIndex
                                                    cannot be present.Still looking to test a no-error IsValid = False case though. :)

Similar Messages

  • Help with Photo Gallery using XML file

    I am creating a photo gallery using Spry.  I used the Photo Gallery Demo (Photo Gallery Version 2) on the labs.adobe.com website.  I was successful in creating my site, and having the layout I want.  However I would like to display a caption with each photo that is in the large view.
    As this example uses XML, I updated my file to look like this:
    <photos id="images">
                <photo path="aff2010_01.jpg" width="263" height="350" thumbpath="aff2010_01.jpg" thumbwidth="56"
                   thumbheight="75" pcaption="CaptionHere01"></photo>
                <photo path="aff2010_02.jpg" width="350" height="263" thumbpath="aff2010_02.jpg" thumbwidth="75"
                   thumbheight="56" pcaption="CaptionHere02"></photo>
                <photo path="aff2010_03.jpg" width="350" height="263" thumbpath="aff2010_03.jpg" thumbwidth="75"
                   thumbheight="56" pcaption="CaptionHere03"></photo>
    </photos>
    The images when read into the main file (index.asp) show the images in the thumbnail area and display the correct image in the picture pain.  Since I added the pcaption field to the XML file, how do I get it to display?  The code in my index.html file looks like this:

    rest of the code here:
            <div id="previews">
                <div id="controls">
                    <ul id="transport">
                        <li><a href="#" class="previousBtn" title="Previous">Previous</a></li>
                        <li><a href="#" class="playBtn" title="Play/Pause" id="playLabel"><span class="playLabel">Play</span><span class="pauseLabel">Pause</span></a></li>
                        <li><a href="#" class="nextBtn" title="Next">Next</a></li>
                    </ul>
                </div>
                <div id="thumbnails" spry:region="dsPhotos" class="SpryHiddenRegion">
                    <div class="thumbnail" spry:repeat="dsPhotos"><a href="{path}"><img alt="" src="{thumbpath}"/></a><br /></div>
                    <p class="ClearAll"></p>
                </div>
            </div>
            <div id="picture">
                <div id="mainImageOutline"><img id="mainImage" alt="main image" src=""/><br /> Caption:  {pcaption}</div>
            </div>
            <p class="clear"></p>
        </div>
    Any help with getting the caption to display would be greatly appreciated.  The Caption {pcaption} does not work,

  • Help with creating a new XML file from an existing DOM tree!!

    i want to create a new XML file from an existing DOM tree
    i used this code to create a new document:
    static public Document createDocument(String fileName) throws ParserConfigurationException//,IOException,SAXException
              try {
                   DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
                   factory.setIgnoringComments(true);
                   factory.setIgnoringElementContentWhitespace(true);
                   factory.setValidating(true);
                   DocumentBuilder builder =factory.newDocumentBuilder();
                   return builder.newDocument();
    //          handle exception creating DocumentBuilder
              catch ( ParserConfigurationException parserError ) {
                        throw new ParserConfigurationException();
              }then i used this code to transform the DOM :
    public void exportDocument(Document document) {
              try {
                   Source xmlSource = new DOMSource( document );
                   Result result = new StreamResult( System.out );
                   TransformerFactory transformerFactory =
                        TransformerFactory.newInstance();
                   Transformer transformer =transformerFactory.newTransformer();
                   transformer.setOutputProperty( "indent", "yes" );
                   transformer.transform( xmlSource, result );
           //then catching the exceptions
    But the file was not created and i didn't find where can i specify the DTD that the XML file should use and where can i enter the name of the XML file itself
    Another questoin can i write a DTD file dynamically during the execution of the program??

    Cross-post: http://forum.java.sun.com/thread.jspa?threadID=784467&messageID=4459240#4459240

  • How can I fill structure from the line with contetnt of a XML file inside?

    How can I fill structure from the line with contetnt of a XML file inside?
    I have array of lines with XML documents inside. All XML's have the same structure.
    I need to fill array of structures (with the same structure like given XML's) from data of these XML's.
    How can I do this? I am trying Transformation with ora:parseEscapedXML, but receive error: "XPath expression failed to execute.
    Error while processing xpath expression, the expression is "ora:processXSLT("Transformation_1.xsl", bpws:getVariableData("ProcessedFiles"))", the reason is javax.xml.transform.TransformerException: javax.xml.transform.TransformerException: Could not find function: parseEscapedXML.
    Please verify the xpath query."

    Ive posted the new code but now I'm getting a FileAlreadyExistException error. How do I handle this exception error correctly in my code?
    import java.io.IOException;
    import java.nio.file.FileAlreadyExistsException;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    import javax.xml.parsers.DocumentBuilder;
    import javax.xml.parsers.DocumentBuilderFactory;
    import javax.xml.parsers.ParserConfigurationException;
    import org.w3c.dom.Document;
    import org.w3c.dom.Element;
    import org.w3c.dom.Node;
    import org.w3c.dom.NodeList;
    import org.xml.sax.SAXException;
    public class MyDomParser {
      public static void main(String[] args) {
      DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
      try {
      DocumentBuilder builder = factory.newDocumentBuilder();
      Document doc = builder.parse("ENtemplate.xml");
      doc.normalize();
      NodeList rootNodes = doc.getElementsByTagName("templates");
      Node rootNode = rootNodes.item(0);
      Element rootElement = (Element) rootNode;
      NodeList templateList = rootElement.getElementsByTagName("template");
      for(int i=0; i < templateList.getLength(); i++) {
      Node theTemplate = templateList.item(i);
      Element templateElement = (Element) theTemplate;
      System.out.println(templateElement.getAttribute("name")+ ".xml");
      for(int i=0; i < templateList.getLength(); i++) {
      Node theTemplate = templateList.item(i);
      Element templateElement = (Element) theTemplate;
      String fileName = templateElement.getAttribute("name") + ".xml";
      Files.createFile(Paths.get(fileName));
      System.out.println("File" + ":" + fileName + ".xml created");
      } catch (ParserConfigurationException e) {
      // TODO Auto-generated catch block
      e.printStackTrace();
      } catch (SAXException e) {
      // TODO Auto-generated catch block
      e.printStackTrace();
      } catch (IOException e) {
      // TODO Auto-generated catch block
      e.printStackTrace();

  • Help -- Who has experience with ant and build.xml files ?

    Hi,
    I think my build.xml file is missing setting a classpath I need, but I have never played around with a build.xml file. Could someone help ?
    Thank you.
    Grazia

    A lot of people here use ant. But not all of us can read your mind, and those of us that can are sadistic bastards that like to force people to provide details of their problems just for the hell of it.
    So please do the following:
    * Go through an ant tutorial or other introductory docs, doing an example or two if present.
    * Set up your build.xml according to what you've learned.
    * If it still doesn't work, post the relevant portions of it (hopefully you'll have a small, representative sample that reproduces the problem), along with your relevant directory and file structure, the command you're running, and what error messages you're getting.

  • Problem Working With Framemaker 9 Dita XML Files in Framemaker 10

    I just upgraded to Framemaker 10. I am encountering a number of problems when I try to work with my Dita XML help topics, which were last saved in Framemaker 9 format.
    1. Using the Default Dita Template
    When I open one of my documents in Framemaker 10, the Dita 1.2 template ditabase.fm is automatically applied. Everything seems fine. But then when I convert the XML to Eclipse help (which is essentially html, so we're going from XML to HTML) using Dita Open Toolkit ant scripts, I see this message:
    [pipeline] [DOTJ013E][ERROR] Failed to parse the referenced file 'html\c_licensing.xml' due to below exception. Please correct the reference base on the exception message.
    [pipeline] c_licensing.xml Line 25:Attribute "xmlns:ditaarch" must be declared for element type "dita".
    I then opened the xml  file in a text editor, and I saw this on line 25:
    <dita xmlns:ditaarch = "http://dita.oasis-open.org/architecture/2005/">
    Line 25 looks fine to me. Am I missing something? 
    2. Switching to a 1.1 Dita Template
    I tried to work around the above problem. In Framemaker, I tried to set a different structured application as the default one. I closed all files and chose the default Dita 1.1 structured application (it defaults to the Dita 1.1. Composite app.)
    Then I tried to open my file: I got this message inside Framemaker:
    "Validation of XML failed. Continue?
    Error at [FILE PATH], line 25, char 72, Message: Attribute '{http://www.w3.org/2000/xmlns/}ditaarch' is not declared for element 'dita'
    Sounds familiar, doesn't it?
    I switched from the default Dita 1.1. Composite structured application to the Dita 1.1. Topic structured application. Then I dirtied the source file and saved it. The messages I got in FrameMaker log window included the one above, plus I got a variety of Unknown Element messages, things like this:
    Unknown element dita,
    unknown element concept,
    various attributes are not declared for concept,
    unknown element conbody.
    If I switch back to the Dita 1.1 Composite application all of these messages diappear except for this one:
    Attribute '{http://www.w3.org/2000/xmlns/}ditaarch' is not declared for element 'dita'
    My ant conversion scripts from the Dita Open Toolkit are still unable to process this file. They give the same message as is listed in (1) above and the file is not converted to HTML.
    Can anyone help me with this problem? I've also posted this question to the Dita Users Group on Yahoo Groups. If I get an answer in one place, I'll post it in the other.
    Thanks,
    Nina P.

    I really appreciate all the help you are providing with this, Scott. I tried your latest suggestions. Here's what happened:
    Application Mappings:
    I figured out how to add my "BigPage" structured application to the Applications Mappings dialog. I made a new "BigPage"  mapping type, then figured out the non-intuitive part: how to add my individual BigPage topic types to it.  I closed and reopened FrameMaker opened my test document, and, as before (before I did the application mappings) I saw my BigPage applications listed in the Structure Tools > Set Structured Application drop-down. I selected the appropriate application (in this case it was DITA1.1-BigPage-Reference-FM and clicked the "Set" button. 
    It is at this point in Framemaker 9 (and also once, in FrameMaker 10, early in this process, but I haven't been able to replicate it since) that the page size would change to tabloid size, indicating that the document was using the template from the BigPage reference structured application, not the regular DITA1.1 reference application. But this did not happen.
    I tried saving the document, closing it, and reopening it. Once again the default structured application assigned to that document was "reset" to DITA1.1-Reference-FM.  But the fact that the page size did not immediate refresh to tabloid size told me that although I did select the BigPage application in the drop-down, it wasn't being applied.
    Public IDs:
    The public ID in my test reference XML file is:  <!DOCTYPE reference PUBLIC "-//OASIS//DTD DITA Reference//EN" "reference.dtd" [
    The four public IDs in the DITA1.1-BigPage-Reference-FM entry in structapps.fm (in the Entity Locations section) are:
    -//OASIS//DTD DITA Reference//EN 
    -//IBM//DTD DITA Reference//EN
    -//OASIS//DTD DITA Composite//EN
    -//IBM//DTD DITA Composite//EN
    Do you see anything wrong with the above? .
    Directory Structure: 
    Maybe I cloned the application incorrectly?  Here's what I did:
    1. In C:\Program Files (x86)\Adobe\AdobeFrameMaker10\Structure\xml, I copied the folder called DITA and pasted it into the same directory. I renamed this folder DITA-BigPage
    2. Inside DITA-BigPage, I opened the app folder. Inside each subfolder in app, DITA-Reference-FM, for example, I opened the edd file in Framemaker. In this case, the edd file name was reference.edd.fm.
    3. I edited the top line of reference.edd.fm.  It originally said:
    Structured Application: DITA1.1-Reference-FM.
    I changed it to say:
    Structured Application: DITA1.1-BigPage-Reference-FM
    4. I saved the EDD file. Then I opened the template file in the same folder. It was called: reference.template.fm.
    5. In reference.template.fm, I first changed my page size: Format Menu > Page Layout > Page Size > Tabloid > Set.
    6. Then I imported the element definitions from the corresponding EDD file:  File > Import > Element Definitions > reference.edd.fm > Click Import > Click OK to dismiss verification message.
    7. I repeated the above process for all topic-type folders. For the maps types, I did not change the page size, as these will never display as topics in my online  help. I did nothing to the dtd folder.
    8. Once all this was done, I opened structapps.fm.  I did the following to all Dita1.1 elements in the structure tree.
    Selected the Dita 1.1 XMLApplication element, for instance, the one named Dita1.1-Reference-FM, copied it, and pasted it underneath the original element.
    The original first few lines in the clone looked like this:
    Application Name: DITA1.1-Reference-FM
          Template:              $STRUCTDIR\xml\DITA\app\DITA-Reference-FM\reference.template.fm
          DTD:                       $STRUCTDIR\xml\DITA\app\dtd\reference.dtd
          Read/write Rules:  $STRUCTDIR\xml\DITA\app\DITA-Reference-FM\reference.rules.fm
          DOCTYPE:              reference
    I changed these lines to look like this, using your suggestion to create a variable for the first part of the URLs to enable speed and accuracy:
           Application Name:      DITA1.1-BigPage-Reference-FM
                   Template:                    $STRUCTDIR\xml\DITA-BigPage\app\DITA-Reference-FM\reference.template.fm
                   DTD:                            $STRUCTDIR\xml\DITA-BigPage\app\dtd\reference.dtd
                   Read/write Rules:        $STRUCTDIR\xml\DITA-BigPage\app\DITA-Reference-FM\reference.rules.fm
                   DOCTYPE:                    reference
    I also changed the "Filename" URLs in the "Entity Locations" section of this XMLApplication clone from  $STRUCTDIR\xml\DITA\app\  to $STRUCTDIR\xml\DITA-BigPage\app\.  Applying the "BigPage" variable I'd created for this purpose made this go quickly.
    Finally, after this didn't work the first few times I tried it, I got suspicious that the structapps.fm file in my AppData folder (in my case, it was in the Roaming subfolder under the usual Adobe directories) was overriding the modified structapps.fm file in the Framemaker program directory so I replaced the one in AppData (it had all the original settings) with my modified version.  This had no effect, unfortunately.
    That was my process. After doing the above, the Dita1.1-BigPage applications all listed in the Set Structured App drop-down. They just didn't work,when applied to my XML documents. Nor did the application "remember" what structured application I had set when I opened a new xml document  or closed/reopened the current document or closed/reopened the application.  Did I place the directories correctly for Framemaker 10?  This is the way I did it for FrameMaker 9 and it worked successfully.
    As much as I'd love to solve this mystery, I've thought of a workaround I can fall back on  that doesn't involve using a cloned application.  I will change the page size of a few of the original Dita1.1 sturctured application templates to tabloid size, but leave the Topic structured application at letter size. I'll then apply the Topic structured application to my PDFs and use the others for my help topics.  I'll set this up now. If this doesn't work, then I'll know there's a much bigger problem at the base of this, perhaps even something to do with changing page sizes in templates.

  • Can anyone help out in parsing the xml file.

    i have this file as string in webdynpro.
    can anyone help out how can i parse it and attch to context of webdynpro with structure
    queryList
       Queryid
       name
       remarks
    <?xml version="1.0" encoding="UTF-8"?>
    <app-data>
    <content-data hyperlink="" name="RegulatoryQueries" status="USER_VALID">
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="4"/>
    <element name="QUERY_NAME" type="Text" value="shal"/>
    <element name="REMARKS" type="Text" value=""/>
    </data><data><element name="QUERY_SAVE_ID" type="Text" value="20"/>
    <element name="QUERY_NAME" type="Text" value="test"/>
    <element name="REMARKS" type="Text" value="test"/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="3"/>
    <element name="QUERY_NAME" type="Text" value="query_shal"/>
    <element name="REMARKS" type="Text" value="shaleel for testing on tomcat"/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="8"/>
    <element name="QUERY_NAME" type="Text" value="sap"/>
    <element name="REMARKS" type="Text" value="Demo"/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="10"/>
    <element name="QUERY_NAME" type="Text" value="TTTTT"/>
    <element name="REMARKS" type="Text" value="TTTTTTTTTTTTTTTTTTTTTtesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttesttestend"/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="6"/>
    <element name="QUERY_NAME" type="Text" value="RagQuery"/>
    <element name="REMARKS" type="Text" value="abcd"/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="16"/>
    <element name="QUERY_NAME" type="Text" value="aa"/>
    <element name="REMARKS" type="Text" value="aaa"/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="12"/>
    <element name="QUERY_NAME" type="Text" value="asda"/>
    <element name="REMARKS" type="Text" value="dasda"/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="5"/>
    <element name="QUERY_NAME" type="Text" value="shalu"/>
    <element name="REMARKS" type="Text" value=""/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="18"/>
    <element name="QUERY_NAME" type="Text" value="qry1234123"/>
    <element name="REMARKS" type="Text" value="aasdf"/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="7"/>
    <element name="QUERY_NAME" type="Text" value="d"/>
    <element name="REMARKS" type="Text" value="sd"/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="13"/>
    <element name="QUERY_NAME" type="Text" value="suresh"/>
    <element name="REMARKS" type="Text" value=""/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="19"/>
    <element name="QUERY_NAME" type="Text" value="qrysdf"/>
    <element name="REMARKS" type="Text" value="sdfsd"/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="22"/>
    <element name="QUERY_NAME" type="Text" value="llk"/>
    <element name="REMARKS" type="Text" value="dffnhjk"/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="25"/>
    <element name="QUERY_NAME" type="Text" value="Query1"/>
    <element name="REMARKS" type="Text" value="Query1"/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="30"/>
    <element name="QUERY_NAME" type="Text" value="1122"/>
    <element name="REMARKS" type="Text" value="w"/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="32"/>
    <element name="QUERY_NAME" type="Text" value="11221"/>
    <element name="REMARKS" type="Text" value=""/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="33"/>
    <element name="QUERY_NAME" type="Text" value="11222"/>
    <element name="REMARKS" type="Text" value=""/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="34"/>
    <element name="QUERY_NAME" type="Text" value="11223"/>
    <element name="REMARKS" type="Text" value=""/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="35"/>
    <element name="QUERY_NAME" type="Text" value="11224"/>
    <element name="REMARKS" type="Text" value=""/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="36"/>
    <element name="QUERY_NAME" type="Text" value="11225"/>
    <element name="REMARKS" type="Text" value=""/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="37"/>
    <element name="QUERY_NAME" type="Text" value="11226"/>
    <element name="REMARKS" type="Text" value=""/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="38"/>
    <element name="QUERY_NAME" type="Text" value="11227"/>
    <element name="REMARKS" type="Text" value=""/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="48"/>
    <element name="QUERY_NAME" type="Text" value="all fields"/>
    <element name="REMARKS" type="Text" value=""/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="50"/>
    <element name="QUERY_NAME" type="Text" value="test34"/>
    <element name="REMARKS" type="Text" value=""/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="27"/>
    <element name="QUERY_NAME" type="Text" value="12"/>
    <element name="REMARKS" type="Text" value="12"/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="61"/>
    <element name="QUERY_NAME" type="Text" value="sureshcharan"/>
    <element name="REMARKS" type="Text" value=""/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="62"/>
    <element name="QUERY_NAME" type="Text" value="charan"/>
    <element name="REMARKS" type="Text" value=""/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="24"/>
    <element name="QUERY_NAME" type="Text" value="sss"/>
    <element name="REMARKS" type="Text" value="sss"/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="64"/>
    <element name="QUERY_NAME" type="Text" value="test"/>
    <element name="REMARKS" type="Text" value=""/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="53"/>
    <element name="QUERY_NAME" type="Text" value="afsdf"/>
    <element name="REMARKS" type="Text" value=""/>
    </data>
    <data>
    <element name="QUERY_SAVE_ID" type="Text" value="51"/>
    <element name="QUERY_NAME" type="Text" value="Satisfy al sets"/>
    <element name="REMARKS" type="Text" value=""/>
    </data>
    </content-data>
    </app-data>
    Thanks.
    dharmendra

    Hi dharmendra,
    Check
    Using the XML returned by XI to populate table in Web Dynpro UI
    Xml File processing
    Best regards, Maksim Rashchynski.

  • Help with Spry Detail Regions, XML Data Sets, for IMG gallery

    Hello,
    I'm working on a site for a friend of mine, a photo gallery. You can see the gallery here, it's a temporary one I'm working on
    http://www.emiliajozefa.com/a_index.html
    Here are some important parts of my code:
    //initially load these data sets. the function will be called by the links to update components later<script type="text/javascript">
         var intNumPhoto = 0;
         dsGallery = new Spry.Data.XMLDataSet("photofile.xml", "galleries/ride/photo");
         dsNav = new Spry.Data.XMLDataSet("photofile.xml", "galleries/ride");
         function updateSpryComponents(galleryDir){
              alert("updating spry components for " + galleryDir);
              intNumPhoto = 0;
              dsGallery = Spry.Data.XMLDataSet("photofile.xml", "galleries/" + galleryDir + "/photo");
              dsNav = Spry.Data.XMLDataSet("photofile.xml", "galleries/" + galleryDir);
              dsGallery.setCurrentRow(intNumPhoto);
              //document.getElementById('nav').innerHTML='<H1>'+enlarge.inp.value+'</H1>';
              document.getElementById('nav').innerHTML=
              "<span spry:detailregion = 'dsGallery'>
             <a href = 'javascript:' onclick = 'if(intNumPhoto > 0){intNumPhoto -= 1}; dsGallery.setCurrentRow(intNumPhoto);'>&lt;</a> {@id} / </span>
             <span spry:detailregion = 'dsNav'>{@numPhotos}
             <a href = 'javascript:' onclick = 'if(intNumPhoto < ({@numPhotos} - 1)){intNumPhoto += 1; }; dsGallery.setCurrentRow(intNumPhoto);'>&gt;</a>
             </span>";
    </script> <--- later ----><!-- SIDEBAR NAV. When link i clicked, set DataSet to the location of the new gallery -->
         <div id = "sideBarNav">
             <a href = "javascript:" onclick ='updateSpryComponents('ride');">Tannersville</a>
                <br />
              <a href = "javascript:" onclick = "updateSpryComponents('dive');">Dive</a>
            <br />
              <a href = "javascript:" onclick = "updateSpryComponents('poland');">Poland</a>
            <br />
              <a href = "javascript:" onclick = "updateSpryComponents('alaska');">Alaska</a>
        </div>
    </div>
    <div id = "content2">
         <!-- PHOTO CONTAINER I think I somehow need to refresh this section of the code to reload new data-->
         <div id = "fotoContainer" spry:detailregion="dsGallery"><img src = "photos/{@path}" width = "{@width}" height = "{@height}"/></div>
         <!-- IMAGE NAVIGATION -->
         <div id = "nav">       
             <span spry:detailregion = "dsGallery" id = "galSpan">
             <a href = "javascript:" onclick = "if(intNumPhoto > 0){intNumPhoto -= 1}; dsGallery.setCurrentRow(intNumPhoto);">&lt;</a> {@id} / </span>
             <span spry:detailregion = "dsNav" id = "navSpan">{@numPhotos}
             <a href = "javascript:" onclick = "if(intNumPhoto < ({@numPhotos} - 1)){intNumPhoto += 1; }; dsGallery.setCurrentRow(intNumPhoto);">&gt;</a>
             </span>
         </div>
    You could view source there to get the code. Here is what I believe is my problem
    I'm trying to automate the site so that when you click on one of the links on the left, without refreshing the page, the paths to the galleries xml file changes, and the spry Detail Regions (1 for the images, 1 for the navigation - left and right arrows). I think the problem is that once the link changes the set and calls my updateSpryComponenets() function, the detail regions need to be refreshed. I'm currently trying to solve this by dynamically rewriting the HTML thru .innterHTML, everytime I call updateSpryComponents().There may also be a problem in the Javascript function updateSpryControllers because if I put the alert after the spry calls, I never get the alert
    Thanks in advance for any help!

    Update:
    Ok, the first query on the Recent tab doesnt work for me because it wont show unless its already voted, and since these are supposed to be new blurts, that kind of breaks the whole site:
    "SELECT Blurt.Id_blurt, Blurt.Name, Blurt.Location, Blurt.Blurt,Blurt.`Date`,DATE_FORMAT(Blurt.`Date`, '%l:%i %p on %M %D, %Y') as Date, ratings.rating_id, Avg(ratings.rating_value) as average_r FROM ratings Left Join Blurt On ratings.rating_id = Blurt.Id_blurt Group By Id_blurt ORDER BY Blurt.`Date` DESC";
    So I replaced it with what I originally had.
    "SELECT Blurt.Id_blurt, Blurt.Name, Blurt.Location, Blurt.Blurt,Blurt.`Date`,DATE_FORMAT(Blurt.`Date`, '%l:%i %p on %M %D, %Y') as Date FROM Blurt ORDER BY Blurt.`Date` DESC";
    But this doesn't provide me with the initial average rating:(

  • Help with flex4unit ant build.xml: Socket timeout waiting for flexunit report

    I'm having trouble setting up ant to build and test my project locally and I'm not sure what the next step is.
    Info:
    Running on XP/Cygwin.
    All of the files that FlexUnit4 references when used in Flash Builder are in my '${basename}/libs' folder (eg FlexUnit4_1.0.swc).
    I've placed the flexunit4 task in my ant/libs folder.
    I'm getting two errors...
    I don't think I've set up the 'socket' stuff right for the tests. It just sits and waits then dies...
    [flexunit] Waiting for client connection ...
    (about a minute later)
    [flexunit] Stopping server ...
    [flexunit] End of test data reached, sending acknowledgement to player ...
    [flexunit] Closing client connection ...
    [flexunit] Closing server on port [1024] ...
    BUILD FAILED
    java.util.concurrent.ExecutionException: Socket timeout waiting for flexunit report
    Plus this is the error I get from the flash player:
    ReferenceError: Error #1065: Variable mx.skins.spark::BorderSkin is not defined.
    I don't know why it's complaining about Borderskin as I think I have included all the flex4 libs I could find. I suspect this second error is causing the first error?
    Any help appreciated. I think I'm just setting it up all wrong.
    Screencap of errors:
    http://twitpic.com/l7ay8
    build.xml:
    http://gist.github.com/20804

    Finally got everything working using the files from the CI Example which what i probably should have done in the first place.
    So a rough guide for anyone just starting out with this:
    Download the Flex 4 'workspace' from the digital primates hudson server . This appears to contain flexunit library and examples in various stages of development.
    I used Flex Builder 4 Beta 2 to set up my Test Suite and Test Cases.
    I then loaded the libs folder from:
    workspace.zip\workspace\project\FlexUnit4SampleCIProject
    into my flex project's libs folder:
    this includes:
    FlexUnit4.swc
    FlexUnit4CIListener.swc
    flexUnit4UIRunner.swc
    flexTasks.jar
    flexUnitTasks.jar
    I didn't need to remove the FlexUnit4 stuff that is 'referenced' automatically by flash builder when you start adding flexunit4 tests/suites.
    Then I used a modified version of the TestRunner.mxml found in:
    workspace.zip\workspace\project\FlexUnit4SampleCIProject\src\test\flex
    The lines to pay attention to are the ones that look like:
    static public function currentRunTestSuite():Array {
        var testsToRun:Array = new Array();
        testsToRun.push(packagename.TestSuiteName);
        testsToRun.push(packagename.TestClassName);
        return testsToRun;
    Just make sure you update this list to include all of the test suites &/or individual tests you want to run.
    I made this a static function and modified the code in the "FlexUnitApplication.mxml" file to use this function so i'd only need to update one list of suites/tests.
    FlexUnitApplication.mxml is generated automatically when you run FlexUnit4 tests in the Flash Builder 4 Beta 2 IDE.
    This is the build.xml file I'm using in the project:
    http://gist.github.com/208211
    Change the name of the project from "Flare" to whatever and adjust the other path settings where required (though you might want to write this from scratch at least once so you understand roughly what is going on).
    The Debug Flash Player must be installed on the server otherwise you'll get a:
    java.util.concurrent.ExecutionException: Socket timeout waiting for flexunit report
    ...while it waits for the non-existant debugger to attach. (This is obvious but I did forget and was a bit bewildered for a moment)
    Need to also ensure the environment variable:FLEX_HOME is set to the location you installed the flex sdk...by editing your .bashrc setting the environment variable the in the Hudson Configuration.
    You'll need to point Hudson at your ant installation and your jdk installation. If you downloaded he sdk, be aware you might need to point it to the jdk folder inside the place you installed the sdk.
    And I think that's all the problems I had. Hope it's useful to someone... if anyone who actually knows what they are doing can point out any potential issues/better ways of doing things, feel free to comment.
    Thanks to Brian (legrosb) and Mike (mlabriola) for their assistance!

  • Help with Flex Ant build.xml error

    So I've started on a new project and I'm new to Flex. A lot of learning curve here. Anyway, I'm trying to deploy a project that uses flex and is built with Ant. We've moving up from a version of Flex 2 to Flex 3. The build file works fine in the Flex 2 app but for some reason does not seem to be working with Flex 3. I'm hoping someone can give me some insight on what might be wrong or where to start.
    The error is Command not found: compc
    The part of the build file it has a problem with is:
    <compc include-classes="${classes}"
         ouput="${flex.dist.dir}/${flex.app.name}.swc"
         keep-generated-actionscript="false"
         headless-server="${headless.server}"
         incremental="true">
    <load_config filename="${FLEX_HOME}/frameworks/flex-config.xml" />
    <source-path path-element="${FLEX_HOME}/frameworks" />
    <source-path path-element="${flex.app.root}" />
    <compiler.library-path dir="${FLEX_HOME}/frameworks" append="true">
         <include name="libs" />
         <include name="../bundles/{local}" />
    </compiler.library-path>
    <compiler.library-path dir="${flex.app.root}" appent="true">
         <include name="libs" />
    </compiler.library-path>
    </compc>
    Any help at all would be greatly appreciated, thank you.

    Sorry, I meant to address that. Yes, since we've moved up to the Flex 3 sdk, we are pointing at a new directory. The old directory was flex_sdk and the new directory is flex_sdk_340.
    FLEX_HOME is being set in the build.properties file for local building and then overidden in the build.xml file with this code:
    <target name="build">
         <available property="FLEX_HOME" value="/apps/flex_sdk_340" file="/apps/flex_sdk_340" />
         <echo>FLEX_HOME = ${FLEX_HOME}</echo>
         <antcall target="compile" />
    </target>
    I did notice a warning about not using the available property, so I removed it and just changed what FLEX_HOME was set to in the build.properties file to the server directory. Would mess up local building but regardless it didn't matter because it had no effect on the error being generated. I alos looked a little into the file property of the available tag trying to figure out if that was somehow an issue but I wasn't able to come to any conclusion.
    Before the program errors out, it does displayt he echo statement and the value of FLEX_HOME appears to be correct in that it does show /apps/flex_sdk_340.
    Thank you so much for your continued help. This is truly frustrating because nothing but a directory name has really changed and yet it stopped working. I can't find any information anywhere on what could be wrong and this is really my last resort.

  • Make a sort with ODI while generating XML File

    Hi all,
    I made a package whith several interfaces and a treatment.
    Each interface targets a table in my XML schema and the final treatment is a CreateXMLFile.
    Everything goes well, my XML file is generated :D
    Now I'd like to make a sort in an XML element. I know how to order the elements between them but can't find a way to sort a specific element. Excuse my poor english, I'm not really clear...
    My XML is built like this :
    <root>
    <questions>
    <question>
    <questionnumber>1</questionnumber>
    </question>
    <question>
    <questionnumber>2</questionnumber>
    </question>
    <questions>
    <root>
    So my problem is to make the questionnumber ordered.
    I tried to modify the IKM SQL Incremental Update to add a ORDER BY in the "Insert new rows" step.
    The generated code is executed with success... but in the end, my XML file is not sorted :S
    So first question, do you have an idea to be able to view the data in my XML schema tables ? This schema is stored in the memory engine and not in an external base. I ask that because when you try to execute the query "select * from XMLSchema.XMLTable" in the Operator, it appears you get the datas you had when the schema had been reversed. Idem when you try to view the datas in datastore. So first of all I'd like to do this control to be sure my order by is taken into account.
    Second question, do you know how the Odi XML driver builds the XML File with the command CreateXMLFile, because I think that my XML table is well sorted but that the CreateXMLFile doesn't repect this order. I checked the driver tutorial but couldn't find any help on that subject.
    So if anyone has got an idea to help me, I would appreciate a lot.
    Thanks,
    Thierry

    Still searching but without success

  • Can anyone help with the scripting on this file?

    Hi, I hope someone with a bigger brain can help me out here.
    I've got an existing Flash CS3 file that makes up the result at http://www.infusion-set.com/flash/Elearning/Inset30/inset30_eguide.html.
    The client has asked if I could add an extra tab at the top after 'Reconnecting' called 'Contact Us' with link to an extra page. All the design has been done in ActionScript 2 with references to XML files for the dynamic content because it's been done in other languages as well.
    I've amended the existing XML file with the correct references for a new page and an accompanying .swf file to play in the animation area.
    I've attempted a .fla version where I duplicated one of the existing tabs script, changed the XML references and changed the variables where necessary to 'con or 'Con' (representing Contact Us). Unfortunately it made the tab menu go completely off the page and was obviously wrong in some way.
    Can anyone give me a clue as to what to change here on the original file as I'm a bit of a novice with ActionScripts, hence me asking.
    For reference I've attached HTML files with the original file scripts and my incorrect version. The  timeline is 103 frames with the scripts placed at frame 1 and 102
    Thanks.
    Garry

    The buttons are all created using the same library object (but MC), except for the code you have in the revised file does not call on that for the con button.
    You have it calling on something with a linkage name of "con", which a quick check tells me doesn't exist--so it is undefined in the code when you try to use it.  I found this by using trace(newConBut._x); after its _x value was assigned, as I mentioned you should try.   So the first thing you want to do is change the following line from...
    var newConBut = _root.attachMovie("con", "conbut", _root.getNextHighestDepth());
    To
    var newConBut = _root.attachMovie("but", "conbut", _root.getNextHighestDepth());
    so that it uses the but MC that serves that purpose in the library.  Then you want to correct the _x assignment of the buttons to what I think you had earlier...
    newConBut._x = 650-newConBut._width;
    newRecBut._x = newConBut._x-newRecBut._width;
    Here is a picture of what those changes do (note, without the XML file I had to finagle things just to work, so the biutton labels aren't what they will be)...

  • Working with multiple faces-config.xml files

    I would organize the menu definitions of my application in different faces-config.xml files. I would also put the label in different properties files.
    The SRDemo application uses a unique properties file for the menu used in the el expression from the faces-config.xml.
    Is it possible to have the same approach with not only one faces-config.xml file but has many faces-config.xml i want for my application.
    If yes does the binding name to be different or may be the same for each file ?

    We still have a litlle problem we don't find the reason. May be you can help us.
    The second menu level never appear in the menu list. The menu list appear as empty.
    The menu bar seem to be correct. We put twice the same model tree to be sure it was working well. Both menu appears. It is correct.
    Here is our faces-config-menu-flexsystem.xml file
    <?xml version="1.0" encoding="windows-1252"?>
    <!DOCTYPE faces-config PUBLIC
    "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.1//EN"
    "http://java.sun.com/dtd/web-facesconfig_1_1.dtd">
    <faces-config xmlns="http://java.sun.com/JSF/Configuration">
    <managed-bean>
    <description>Create menu item for flex system management</description>
    <managed-bean-name>menu_menuitem_FlexSystem_Create</managed-bean-name>
    <managed-bean-class>flex.view.util.MenuItem</managed-bean-class>
    <managed-bean-scope>session</managed-bean-scope>
    <managed-property>
    <property-name>label</property-name>
    <value>#{resources['menu.FlexSystem.menuItem.create']}</value>
    </managed-property>
    <managed-property>
    <property-name>viewId</property-name>
    <null-value/>
    </managed-property>
    <managed-property>
    <property-name>outcome</property-name>
    <value>linkToCreateNewFlexSystem</value>
    </managed-property>
    </managed-bean>
    <managed-bean>
    <description>Manage menu item for flex system management</description>
    <managed-bean-name>menu_menuitem_FlexSystem_Manage</managed-bean-name>
    <managed-bean-class>flex.view.util.MenuItem</managed-bean-class>
    <managed-bean-scope>session</managed-bean-scope>
    <managed-property>
    <property-name>label</property-name>
    <value>#{resources['menu.FlexSystem.menuItem.manage']}</value>
    </managed-property>
    <managed-property>
    <property-name>viewId</property-name>
    <value>\FlexHome.jspx</value>
    </managed-property>
    <managed-property>
    <property-name>outcome</property-name>
    <value>linkToManageFlexSystem</value>
    </managed-property>
    </managed-bean>
    <managed-bean>
    <description>Root menu item for flex system management</description>
    <managed-bean-name>menu_menuitem_FlexSystem_Root</managed-bean-name>
    <managed-bean-class>flex.view.util.MenuItem</managed-bean-class>
    <managed-bean-scope>session</managed-bean-scope>
    <managed-property>
    <property-name>children</property-name>
    <list-entries>
    <value-class>flex.view.util.MenuItem</value-class>
    <value>#{menu_menuitem_FlexSystem_Create}</value>
    <value>#{menu_menuitem_FlexSystem_Manage}</value>
    </list-entries>
    </managed-property>
    <managed-property>
    <property-name>label</property-name>
    <value>#{resources['menu.FlexSystem.menuItem.root']}</value>
    </managed-property>
    </managed-bean>
    <application>
    <message-bundle>flex.view.resources.MenuFlexSystemProperties</message-bundle>
    <locale-config>
    <supported-locale>fr_CH</supported-locale>
    </locale-config>
    </application>
    <managed-bean>
    <managed-bean-name>resources</managed-bean-name>
    <managed-bean-class>flex.view.util.ResourceAdapter</managed-bean-class>
    <managed-bean-scope>session</managed-bean-scope>
    </managed-bean>
    <navigation-rule>
    <from-view-id>/FlexHome.jspx</from-view-id>
    <navigation-case>
    <from-outcome>linkToCreateNewFlexSystem</from-outcome>
    <to-view-id>/CreateNewFlexSystem.jspx</to-view-id>
    </navigation-case>
    </navigation-rule>
    <navigation-rule>
    <from-view-id>/FlexHome.jspx</from-view-id>
    <navigation-case>
    <from-outcome>linkToManageFlexSystem</from-outcome>
    <to-view-id>/ManageFlexSystem.jspx</to-view-id>
    </navigation-case>
    </navigation-rule>
    <managed-bean>
    <managed-bean-name>menu_FlexSystem</managed-bean-name>
    <managed-bean-class>flex.view.util.MenuTreeModelAdapter</managed-bean-class>
    <managed-bean-scope>session</managed-bean-scope>
    <managed-property>
    <property-name>childProperty</property-name>
    <value>children</value>
    </managed-property>
    <managed-property>
    <property-name>listInstance</property-name>
    <list-entries>
    <value-class>flex.view.util.MenuItem</value-class>
    <value>#{menu_menuitem_FlexSystem_Root}</value>
    <value>#{menu_menuitem_FlexSystem_Root}</value>
    </list-entries>
    </managed-property>
    </managed-bean>
    <managed-bean>
    <managed-bean-name>menuModel</managed-bean-name>
    <managed-bean-class>flex.view.util.MenuModelAdapter</managed-bean-class>
    <managed-bean-scope>session</managed-bean-scope>
    <managed-property>
    <property-name>viewIdProperty</property-name>
    <value>viewId</value>
    </managed-property>
    <managed-property>
    <property-name>instance</property-name>
    <value>#{menu_FlexSystem.model}</value>
    </managed-property>
    </managed-bean>
    </faces-config>

  • Help with exporting Deski to text file via Web Intelligence

    We are currently converting from BO version 5 to BO XI rev2. I have a report that must be scheduled to a flie in plain text format. I am using a deski report. When I save as to text, the file is fine. When I schedule it in webi, the file seems to be missing the end of line character for each row in the table, so it cannot be used for an import to another program. Can anybody help with this?-

    well, in that case you need to determine if this issue only happens with a perticular report or all of them, if it happens only with reports imported from 5.x or with newly created reports as well.
    Looks like it is happening only when report is exported from Infoview, not in the Deski client. This might indicate a problem at the Web Apllication server (tomcat or one you use).
    If this issue is happening with any report - it might be a bug. In that case you have no options as there are no more patches for XIR2.
    On the other hand - if all you need is to extract data for consumption in another tool , why not use Data integrator instead ?
    Also, if this desn't work in Deski - does it work if you convert your reports to webi and export from those ?

  • Problem with base64 encoding an xml file with accented characters

    Oracle 10.2.0.1.0 Enterprise Edition running under windows 2003 server
    DB Characterset UTF-8
    I have a routine which takes an xml file and base64 encodes it, and the base64encoded text is stored in a clob column of a table.
    The xml file is stored in UTF-8 format.
    The routine works correctly, except when there are accented characters.
    I am using dbms_lob.loadclobfrom file to load the file.
    DBMS_LOB.OPEN(src_clob, DBMS_LOB.LOB_READONLY);
        DBMS_LOB.LoadCLOBFromFile(
              DEST_LOB     => dest_clob
            , SRC_BFILE    => src_clob
            , AMOUNT       => DBMS_LOB.GETLENGTH(src_clob)
            , DEST_OFFSET  => dst_offset
            , SRC_OFFSET   => src_offset
            , BFILE_CSID   =>dbms_lob.default_csid
            , LANG_CONTEXT => lang_ctx
            , WARNING      => warning
        DBMS_LOB.CLOSE(src_clob);base 64 encoded xml with accented character -- incorrect
    PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4NCjxncDpBcHBs
    aWNhdGlvblByb2ZpbGUgeG1sbnM6eHNpPSJodHRwOi8vd3d3LnczLm9yZy8yMDAx
    L1hNTFNjaGVtYS1pbnN0YW5jZSINCiAgICB4c2k6c2NoZW1hTG9jYXRpb249Imh0
    dHA6Ly9uYW1lc3BhY2VzLmdsb2JhbHBsYXRmb3JtLm9yZy9zeXN0ZW1zLXByb2Zp
    bGVzLzEuMS4wIGh0dHA6Ly9uYW1lc3BhY2VzLmdsb2JhbHBsYXRmb3JtLm9yZy9z
    eXN0ZW1zLXByb2ZpbGVzLzEuMS4wL0dQLnN5c3RlbXMucHJvZmlsZXMuMS4xLjAu
    QXBwbGljYXRpb25Qcm9maWxlLnhzZCINCiAgICB4bWxuczpncD0iaHR0cDovL25h
    bWVzcGFjZXMuZ2xvYmFscGxhdGZvcm0ub3JnL3N5c3RlbXMtcHJvZmlsZXMvMS4x
    LjAiDQogICAgVW5pcXVlSUQ9Ik1FIiBQcm9maWxlVmVyc2lvbj0iMS4xLjAiIEVy
    cmF0YVZlcnNpb249IjAiPg0KICAgIDxncDpEZXNjcmlwdGlvbj5Gb3J1bSBUZXN0
    PC9ncDpEZXNjcmlwdGlvbj4NCiAgICA8Z3A6RGF0YUVsZW1lbnQgTmFtZT0iw6Fj
    Y2VudCIgRXh0ZXJuYWw9InRydWUiIFR5cGU9IkJ5dGVTdHJpbmciIEVuY29kaW5n
    PSJIRVgiIEZpeGVkTGVuZ3RoPSJmYWxzZSIgTGVuZ3RoPSIxNiIgUmVhZFdyaXRl
    PSJ0cnVlIiBVcGRhdGU9InRydWUiIE9wdGlvbmFsPSJ0cnVlIiAvPiAgICANCjwv
    Z3A6QXBwbGljYXRpb25Qcm9maWxlPg0Kbase 64 encoded xml without accented character -- correct
    PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4NCjxncDpBcHBs
    aWNhdGlvblByb2ZpbGUgeG1sbnM6eHNpPSJodHRwOi8vd3d3LnczLm9yZy8yMDAx
    L1hNTFNjaGVtYS1pbnN0YW5jZSINCiAgICB4c2k6c2NoZW1hTG9jYXRpb249Imh0
    dHA6Ly9uYW1lc3BhY2VzLmdsb2JhbHBsYXRmb3JtLm9yZy9zeXN0ZW1zLXByb2Zp
    bGVzLzEuMS4wIGh0dHA6Ly9uYW1lc3BhY2VzLmdsb2JhbHBsYXRmb3JtLm9yZy9z
    eXN0ZW1zLXByb2ZpbGVzLzEuMS4wL0dQLnN5c3RlbXMucHJvZmlsZXMuMS4xLjAu
    QXBwbGljYXRpb25Qcm9maWxlLnhzZCINCiAgICB4bWxuczpncD0iaHR0cDovL25h
    bWVzcGFjZXMuZ2xvYmFscGxhdGZvcm0ub3JnL3N5c3RlbXMtcHJvZmlsZXMvMS4x
    LjAiDQogICAgVW5pcXVlSUQ9Ik1FIiBQcm9maWxlVmVyc2lvbj0iMS4xLjAiIEVy
    cmF0YVZlcnNpb249IjAiPg0KICAgIDxncDpEZXNjcmlwdGlvbj5Gb3J1bSBUZXN0
    PC9ncDpEZXNjcmlwdGlvbj4NCiAgICA8Z3A6RGF0YUVsZW1lbnQgTmFtZT0iYWNj
    ZW50IiBFeHRlcm5hbD0idHJ1ZSIgVHlwZT0iQnl0ZVN0cmluZyIgRW5jb2Rpbmc9
    IkhFWCIgRml4ZWRMZW5ndGg9ImZhbHNlIiBMZW5ndGg9IjE2IiBSZWFkV3JpdGU9
    InRydWUiIFVwZGF0ZT0idHJ1ZSIgT3B0aW9uYWw9InRydWUiIC8+ICAgIA0KPC9n
    cDpBcHBsaWNhdGlvblByb2ZpbGU+DQo=the xml file in use is
    <?xml version="1.0" encoding="UTF-8"?>
    <gp:ApplicationProfile xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://namespaces.globalplatform.org/systems-profiles/1.1.0 http://namespaces.globalplatform.org/systems-profiles/1.1.0/GP.systems.profiles.1.1.0.ApplicationProfile.xsd"
        xmlns:gp="http://namespaces.globalplatform.org/systems-profiles/1.1.0"
        UniqueID="ME" ProfileVersion="1.1.0" ErrataVersion="0">
        <gp:Description>Forum Test</gp:Description>
        <gp:DataElement Name="áccent" External="true" Type="ByteString" Encoding="HEX" FixedLength="false" Length="16" ReadWrite="true" Update="true" Optional="true" />   
    </gp:ApplicationProfile>The file is being loaded from a windows xp professional 32 bit system.
    If I just convert the xml text of the file using
    select utl_raw.cast_to_varchar2(
    utl_encode.base64_encode(
    utl_raw.cast_to_raw(
    '<?xml version="1.0" encoding="UTF-8"?>
    <gp:ApplicationProfile xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://namespaces.globalplatform.org/systems-profiles/1.1.0 http://namespaces.globalplatform.org/systems-profiles/1.1.0/GP.systems.profiles.1.1.0.ApplicationProfile.xsd"
        xmlns:gp="http://namespaces.globalplatform.org/systems-profiles/1.1.0"
        UniqueID="ME" ProfileVersion="1.1.0" ErrataVersion="0">
        <gp:Description>Forum Test</gp:Description>
        <gp:DataElement Name="áccent" External="true" Type="ByteString" Encoding="HEX" FixedLength="false" Length="16" ReadWrite="true" Update="true" Optional="true" />   
    </gp:applicationprofile>'
    ))) from dual;I get the following
    PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPGdwOkFwcGxp
    Y2F0aW9uUHJvZmlsZSB4bWxuczp4c2k9Imh0dHA6Ly93d3cudzMub3JnLzIwMDEv
    WE1MU2NoZW1hLWluc3RhbmNlIgogICAgeHNpOnNjaGVtYUxvY2F0aW9uPSJodHRw
    Oi8vbmFtZXNwYWNlcy5nbG9iYWxwbGF0Zm9ybS5vcmcvc3lzdGVtcy1wcm9maWxl
    cy8xLjEuMCBodHRwOi8vbmFtZXNwYWNlcy5nbG9iYWxwbGF0Zm9ybS5vcmcvc3lz
    dGVtcy1wcm9maWxlcy8xLjEuMC9HUC5zeXN0ZW1zLnByb2ZpbGVzLjEuMS4wLkFw
    cGxpY2F0aW9uUHJvZmlsZS54c2QiCiAgICB4bWxuczpncD0iaHR0cDovL25hbWVz
    cGFjZXMuZ2xvYmFscGxhdGZvcm0ub3JnL3N5c3RlbXMtcHJvZmlsZXMvMS4xLjAi
    CiAgICBVbmlxdWVJRD0iTUUiIFByb2ZpbGVWZXJzaW9uPSIxLjEuMCIgRXJyYXRh
    VmVyc2lvbj0iMCI+CiAgICA8Z3A6RGVzY3JpcHRpb24+Rm9ydW0gVGVzdDwvZ3A6
    RGVzY3JpcHRpb24+CiAgICA8Z3A6RGF0YUVsZW1lbnQgTmFtZT0iw6FjY2VudCIg
    RXh0ZXJuYWw9InRydWUiIFR5cGU9IkJ5dGVTdHJpbmciIEVuY29kaW5nPSJIRVgi
    IEZpeGVkTGVuZ3RoPSJmYWxzZSIgTGVuZ3RoPSIxNiIgUmVhZFdyaXRlPSJ0cnVl
    IiBVcGRhdGU9InRydWUiIE9wdGlvbmFsPSJ0cnVlIiAvPiAgICAKPC9ncDphcHBs
    aWNhdGlvbnByb2ZpbGU+Edited by: Keith Jamieson on Jul 13, 2012 9:59 AM
    added code tag for last base64 encoded object

    Not sure if utl_i18n is already there in version prior to 11.2.0.2.
    But on above mentioned version I can do the simplified method
    SQL> SELECT utl_i18n.raw_to_char (
             utl_encode.base64_encode (
               xmltype (
                 '<?xml version="1.0" encoding="UTF-8"?>
    <gp:ApplicationProfile xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://namespaces.globalplatform.org/systems-profiles/1.1.0 http://namespaces.globalplatform.org/systems-profiles/1.1.0/GP.systems.profiles.1.1.0.ApplicationProfile.xsd"
        xmlns:gp="http://namespaces.globalplatform.org/systems-profiles/1.1.0"
        UniqueID="ME" ProfileVersion="1.1.0" ErrataVersion="0">
        <gp:Description>Forum Test</gp:Description>
        <gp:DataElement Name="áccent" External="true" Type="ByteString" Encoding="HEX" FixedLength="false" Length="16" ReadWrite="true" Update="true" Optional="true" />   
    </gp:ApplicationProfile>').getblobval (
                 NLS_CHARSET_ID ('utf8'))),
             'utf8')
             x
      FROM DUAL
    X                                                                                                                                                    
    PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPGdwOkFwcGxp                                                                                     
    Y2F0aW9uUHJvZmlsZSB4bWxuczp4c2k9Imh0dHA6Ly93d3cudzMub3JnLzIwMDEv                                                                                     
    WE1MU2NoZW1hLWluc3RhbmNlIiB4c2k6c2NoZW1hTG9jYXRpb249Imh0dHA6Ly9u                                                                                     
    YW1lc3BhY2VzLmdsb2JhbHBsYXRmb3JtLm9yZy9zeXN0ZW1zLXByb2ZpbGVzLzEu                                                                                     
    MS4wIGh0dHA6Ly9uYW1lc3BhY2VzLmdsb2JhbHBsYXRmb3JtLm9yZy9zeXN0ZW1z                                                                                     
    LXByb2ZpbGVzLzEuMS4wL0dQLnN5c3RlbXMucHJvZmlsZXMuMS4xLjAuQXBwbGlj                                                                                     
    YXRpb25Qcm9maWxlLnhzZCIgeG1sbnM6Z3A9Imh0dHA6Ly9uYW1lc3BhY2VzLmds                                                                                     
    b2JhbHBsYXRmb3JtLm9yZy9zeXN0ZW1zLXByb2ZpbGVzLzEuMS4wIiBVbmlxdWVJ                                                                                     
    RD0iTUUiIFByb2ZpbGVWZXJzaW9uPSIxLjEuMCIgRXJyYXRhVmVyc2lvbj0iMCI+                                                                                     
    CiAgPGdwOkRlc2NyaXB0aW9uPkZvcnVtIFRlc3Q8L2dwOkRlc2NyaXB0aW9uPgog                                                                                     
    IDxncDpEYXRhRWxlbWVudCBOYW1lPSLDoWNjZW50IiBFeHRlcm5hbD0idHJ1ZSIg                                                                                     
    VHlwZT0iQnl0ZVN0cmluZyIgRW5jb2Rpbmc9IkhFWCIgRml4ZWRMZW5ndGg9ImZh                                                                                     
    bHNlIiBMZW5ndGg9IjE2IiBSZWFkV3JpdGU9InRydWUiIFVwZGF0ZT0idHJ1ZSIg                                                                                     
    T3B0aW9uYWw9InRydWUiLz4KPC9ncDpBcHBsaWNhdGlvblByb2ZpbGU+Cg==                                                                                         
    1 row selected.which encodes and decodes properly on my system even with accented characters.

Maybe you are looking for

  • Validation not working during Mass Change of Vendor Line Items

    Hi All, I created validation for Reference Key 1 field of Vendor line items, in this validation i used customized user exit. Whenever i select multiple line items in FBL1N for mass change & try to put a unauthenticated value system gives error as per

  • I can't eject my external hard drive

    Trying to transfer files from external hard drive to macbook. Downloading photos has stopped, no photos downloaded and the window with the download message is frozen to my screen. When I try to eject the hd I get this message:The volume can't be ejec

  • Can't edit default domain controllers policy on windows 8 or server 2012

    I have found that I can't edit the "Default Domain Controllers Policy" from a Windows 8 or Server 2012 machine.  I can edit and save changes fine from a Windows 7 machine.  The domain controllers are running Windows 2012 Standard upgraded from Window

  • FERT -  PRT -  EQUIPMENT   FOR TOOL MAINTENANCE USING PM CONCEPT.

    Hello, I need to convert the finished product (produced in our toolroom) to PRT and maintain them as equipment. By this the maintenance cost can be easily captured for these equipment PRT. It will be helpful if anyone can guide me for step by step pr

  • Access to Weblogic 7.0 SP1 datasource throws Oracle Exception

    Hi, I am trying to access a DataSource & Connection Pool set up in a Weblogic 7.0 SP1 instance, from a client app running in a different JVM than the app server itself. The code I used is given below, Hashtable ht = new Hashtable(); ht.put(Context.IN