Merging X XML files, sorting the resultlist and finally execute a distinct?

I have several questions about an XSLT file that I should write:
1� First, I get X paths to XML files. It can be 2, 3, 4, ... whatever a number. I don't know exactly the total amount of XML files.
I need to merge them dynamicly to one resultset.
2� Next, I need to sort them on a specific node (remark: every XML file has the same DOM tree)
3� Finally, I want to distinct the values because some of the nodes are in file 1, 2, 3 ... So I don't want duplicates.
I guess this is not possible in XSLT? I can't use Java, so it should be done using XSLT ;;;

Have a look here:
[http://www.jenitennison.com/xslt/index.html|http://www.jenitennison.com/xslt/index.html]
under the "Sorting" and "Grouping" sections. Also consider using XSLT 2.0, which has built-in grouping elements which make the convoluted XSLT 1.0 techniques unnecessary.

Similar Messages

  • Hello Anybody, I have a question. Can any of you please suggest me how to make an xml file from the database table with all the rows? Note:- I am having the XSD Schema file and the resulted XML file should be in that XSD format only.

    Hello Anybody, I have a question. Can any of you please suggest me how to make an xml file from the database table with all the records?
    Note:- I am having the XSD Schema file and the resulted XML file should be in that XSD format only.

    The Oracle documentation has a good overview of the options available
    Generating XML Data from the Database
    Without knowing your version, I just picked 11.2, so you made need to look for that chapter in the documentation for your version to find applicable information.
    You can also find some information in XML DB FAQ

  • Is a copy of .xml file on the iPod too? If so, how can I copy ONLY the .xml file to my computer and NOT have to copy all my music files too?

    I had to re-load my OS (Windows XP Pro) from a HD snapshot via Acronis True Image Server. I save my OS on my C: drive and all my data files on my D: drive.  So when I re-loaded my OS, I still have all of my music files intact.
    I have re-loaded the OS before and had to re-create iTunes library which I did by doing the follwing:
    1. cut & paste .xml file in iTunes folder to desktop
    2. delete .itl file in iTunes folder
    3. import .xml file through iTunes  file>library>iport playlist
    4. navigate to .xml file on desktop and import
    This worked last time I re-loaded my OS but not this time for some reason.
    So I'm wondering if there is a copy of the .xml file on the iPod itself in the iPod_Control folder that I can copy and paste to my comuter desktop and import via the above steps?
    I have seen all kinds of solutions on the web that include copying the music files from the iPod to the computer.  I don't need to do that.  I have the music files.  I just need the .xml file so iTunes can talk to my iPod (5th Generation - 30G).

    Backup your music library, that is the only way to ensure it does not go missing through theft, damage, operator error, machine breaks, upgrades go wrong, operator goes wrong .........

  • How to Merge multiple XML  files in one file ( Env: XML Publisher 5.6.2)

    All,
    I have recently started working on XML publisher and have developed 3 reports in last 2 days using XML Publisher and integrating them with Concurrent programs.
    This is a great tool.
    I have got another requirement, where i need to use xml file generated by multiple run of same report with various parameters and then merge all xml file to a single report. Developing the whole custom process will take very long time and sure will have bugs in it. Instead i was thinking to use xml file generated by Oracle report itself.
    Report "US Gross to net summary" generates xml output in standard output directory and then show output in PDF file. I have 7 such file generated for each payroll. I want to merge output of xml into a single xml so that i can create single report having data from all 7 xml files showing me All payroll output in a single report.
    Can someone please guide me , how can i read xml file data from the output directory of a seeded concurrent program and how to manipulate data in it.
    Thanks
    Ankur

    Hi Tim,
    Thanks for replying. I have looked for "PDFBookBinder class" in xml publisher user guide for ver 5.6.2. I didn't get any reference of this text. Can you please guide me to a tutorial/link where i can get more information about this class.
    Also, i originally thought of similar to your second logic, as my design basis. Oracle process generates the xml file in output directory which i can get. What i didn't get is how do i "pick them up and merge" using publisher. Also, is there way to do this merging process using pl/sql ? Can you please give little more information on your second approach.
    My original plan of action is that i will create a report set in which i will call oracle seeded report for all 7 payrolls in a sequential manner. Then using the child requests of the report set i will get to 7 xml files generated by seeded oracle process. Then the piece i am not sure of , i will use those 7 files to generate a single xml file having payroll name as tree top for each output. Once single xml is ready, i can easily design a template and register the process to generate output as Excel.This process will not require me to actually change any data or do any calculation. It will only reformatting the feilds we see and abiity to see all 7 payroll at one time rather then entering these numbers manually into an excel to do analysis.
    Please provide your feedback, if you think above plan is not feasible or need corrections.
    Best Regards,
    Ankur

  • Merging many XML files in diff directories

    I need to create a java program to merge many XML files in diff directories.
    Is there any standard code to do this?

    I need to create a java program to merge many XML
    files in diff directories.
    Is there any standard code to do this?Hi,
    For a document to be well formed or a valid XML document it should have only 1 root element containing other elements.
    So in case you want to merge different documents you need to create a new root element and append the child nodes of the different XML documents you want to merge excluding the first processing instruction containing the XML version and encoding.
    If you are sure that these XML that you are talking about are well formed then you can achieve this by simple File I/O. create a file create write the root element and then one by one copy the contents of other xml files except the first entity if any. Finally write the closing tag of the root element and you are done.
    Regards,
    Rajagopal

  • Error while extracting XML file from the application server

    Hi ,
    I am writing a XML file into the application server, after which when i try to extract the file to the local server using the report - RFASLDPC ,
    the file is extracted, but with a '#' symbol at the first position.
    Because of which the XML File does not open. But after i open the file in notepad and manually delete the '#' symbol and then reopen the file, it works fine.
    Is there any way to remove the '#' symbol while extracting itself ??
    Thanks in advance,
    Vikas.

    Select the option "No Character Set Conversion" in stead of Code page 1100.
    However, I still have troubles -> the downloaded xml file misses a space on several places. This causes errors too.

  • Not able to open XML file in the application server..........

    Hi,
    I have downloaded a XML file to the application server.....
    File is created but i am not able to open the file there....
    Plz advice ....how to open it.....
    Regards.

    Use Notepad. Drag and drop in notepad.
    Aman

  • Reading an xml file in the web services java file

    I want to read some data in the webservices file.so i am writing my own xml file through which i want to read data.but i am not able to read xml file from web services file.also , i am not able to put xml file in the .ear file,as there is no such tag in servicegen script through which i can add xml file in the .ear file.
    i know in case of servlets,i will specify context-param attributes in web.xml,and i can access those in my servlet.can i do anything like this for webservices,and i am not using any servlets for web services.
    kindly tell any solution.

    One possible option to parse an xml-file to a flex XML object:
    public function parseConXML(source:String):void
                    xmlLoader = new URLLoader();
                    xmlLoader.load(new URLRequest(source));
                      // Eventlistener: if URL loaded --> onLoadComplete function
                      xmlLoader.addEventListener(Event.COMPLETE, xmlLoadComplete);
                public function xmlLoadComplete(evt:Event):void{               
                    var xml:XML = new XML();
                     // ignore comments in XML-File
                    XML.ignoreComments = true;  
                       //ignore whitespaces in XML-File
                     XML.ignoreWhitespace = true;
                    // XML-Objekt erstellen
                    xml = new XML(evt.target.data);
                   //AFTERWARDS use your xml as your wish

  • How to read a XML file from BLOB column and insert in a table - PL/SQL Only

    Hi,
    To make data load more simple to end user instead placing file on the server and use SQL-LOADER, I came up with new idea that using oracle ebusiness suite attachment functionality. that loads a XML file from local PC to a database column(table is fnd_attachments, default data type is BLOB over here).
    I tried with DBMS_LOB and didnt get around.
    Please can anyone tell me how to read the BLOB column using PL/SQL and store the data in a oracle table. Here's the sample XML file and table structure FYI.
    <?xml version="1.0" encoding="UTF-8"?>
    <dataroot xmlns:od="urn:schemas-microsoft-com:officedata" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="Corporate_alloc.xsd" generated="2009-07-07T14:17:49">
    <Corporate_alloc>
    <PKG_CODE>BKCORP</PKG_CODE>
    <PKG_NAME>Corporate Edition - Books</PKG_NAME>
    <DET_CODE>B9780080543758</DET_CODE>
    <DET_NAME>Waves, Tides and Shallow-Water Processes</DET_NAME>
    <ALLOCATION_RATIO>0.000041</ALLOCATION_RATIO>
    </Corporate_alloc>
    <Corporate_alloc>
    <PKG_CODE>BKCORP</PKG_CODE>
    <PKG_NAME>Corporate Edition - Books</PKG_NAME>
    <DET_CODE>B9780080534343</DET_CODE>
    <DET_NAME>Hydrostatically Loaded Structures</DET_NAME>
    <ALLOCATION_RATIO>0.000127</ALLOCATION_RATIO>
    </Corporate_alloc>
    </dataroot>
    CREATE TABLE TEST_XML
    ( PKG_CODE VARCHAR2(50),
    PKG_NAME VARCHAR2(100),
    DET_CODE VARCHAR2(20),
    DET_NAME VARCHAR2(500),
    ALLOCATION_RATIO NUMBER )
    Thanks
    EBV

    In regards to #3, use the COLUMNS functionality of XMLTable instead of using Extract. Two simple examples are
    Re: XML Data - Caliculate fields
    Re: Extractvalue function not recognised

  • Upload an XML file into the Internal table

    Hi Guys,
    I want to know, how to upload an xml file into the Internal table through ABAP programming

    you just wanted to load the xml file into internal table (as a table of binary strings)or load the xml data mapped to itab row columns
    for the first one you can simply use gui_upload
    and for the second one you need to load the xml file using gui_upload and use XLST program to transform into an itab
    Regards
    Raja

  • How to update XML file from the program

    i am new in abap , and i have the following issue,so plz anyone who knows how to do it
    Background :
    An XML file is used as the datasource for a Flex Application. From time to time this requires updating with new staff details.
    i have already saved the xml file in the c drive with the name C:\AdvAC\AC1\bin-debug\assets\staff
    Requirement :  Write a Dialog transaction with the following text input fields.
    Reference Indicator.     (Char10)
    Staff No          (NUMC, Length 5)
    Name               (Char50)
    Room               (Numc, length 3)
    Phone               (Numc Length 7)
    Mail               (char30)
    in screen 100
    The transaction should also have an u201CUpdate Fileu201D button, which when pressed :
    1) Loads the file C:\AdvAC\AC1\bin-debug\assets \ into an ITAB.
    2) Inserts the data into the ITAB using the following XML format.
    <staff>
    <ref_ind> Reference Indicator.</ref_ind>
    <staff_no> Staff No </staff_no>
    <name> Name </name>
    <room> Room </room>
    <phone> Phone </phone>
    <mail> Mail </mail>
    </staff>
    all should be inside  <allstaff> </allstaff> tagsu2026.
    Writes the ITAB back to the file.
    thanx all

    this is what i have done but i dont know how to do the rest. i will apprecite any help from u.
    Edited by: man700s on Feb 16, 2010 6:58 AM
    REPORT  Z_XML_FILE_UPDATE.
    TYPES: BEGIN OF ts_staff,
             REF_IND(10)  TYPE c,
             Staff_No(5)  TYPE c,
             Name(50)     TYPE c,
             Room(3)      Type n,
             Phone(7)     Type n,
             Mail(30)     Type c,
           END OF ts_staff.
    DATA: t_staff TYPE TABLE OF ts_staff WITH HEADER LINE.
    DATA: w_staff Type ts_staff.
    DATA T_STRING TYPE TABLE OF STRING.
    DATA W_STRING TYPE STRING.
    call SCREEN 100.
    PERFORM upload_xml_file.
    PERFORM update_xml_tab.
    *PERFORM download_xml_file.
    MODULE USER_COMMAND_0100 INPUT.
    W_STRING = '<allstaff>'.
      APPEND w_string to t_string.
      loop at t_staff into w_staff.
      w_string ='<staff>'.
      APPEND w_string to t_string.
      if T_staff-Ref_Ind = 'X'.
      CONCATENATE '<Ref_Ind>' w_staff-Ref_Ind '</Ref_Ind>' into w_string.
      APPEND w_string to t_string.
      ENDIF.
      if T_staff-staff_no = 'X'.
      CONCATENATE '<staff_no>' w_staff-staff_no '</staff_no>' into w_string.
      APPEND w_string to t_string.
      ENDIF.
      if T_staff-name = 'X'.
      CONCATENATE '<name>' w_staff-name '</name>' into w_string.
      APPEND w_string to t_string.
      ENDIF.
    if T_staff-room = 'X'.
      CONCATENATE '<room>' w_staff-room '</room>' into w_string.
      APPEND w_string to t_string.
      ENDIF.
      if T_staff-phone = 'X'.
      CONCATENATE '<phone>' w_staff-phone '</phone>' into w_string.
      APPEND w_string to t_string.
      ENDIF.
      if T_staff-mail = 'X'.
      CONCATENATE '<mail>' w_staff-mail '</mail>' into w_string.
      APPEND w_string to t_string.
      ENDIF.
      w_string = '</staff>'.
      append w_string to t_string.
    ENDLOOP.
      W_STRING = '</allstaff>'.
      APPEND w_string to t_string.
    ENDMODULE.               
    Edited by: man700s on Feb 16, 2010 7:01 AM

  • Creating XML files with the DME

    Hi All,
    I'm working on an integration project between my company and HSBC, they are requesting that we supply our AP payment files for foreign currency in XML format.
    I have some limited experience with the DME and know it can create XML files, however, the elements available for XML files are different to standard flat files. Also it doesnt seem like I can create files with multiple levels? e.g.
    <InitgPty>
    ......... <Id>
    ............... <OrgId>
    ...................... <BkPtyId>ABC00103003</BkPtyId>
    .............. </OrgId>
    ........ </Id>
    </InitgPty>
    Does anyone have any documentation or experience with creating XML files with DME?
    thanks
    Phil.

    Hi,
    Please ask any Implementation team in ABAB or Report painter team with your friends,
    Thanks and REgards
    N.Soma Sundaram

  • How to merge many XML files into one?

    Hi: I got a small project to combine many XML files into one and convert the combined XML file in Excel using AppleScript. My XML files look like this:
    <?xml version="1.0" encoding="UTF-8"?>
    <Metadataobject>
        <from>[email protected]</from>
        <jobname>B3_IM09MBDUF</jobname>
        <pages>2</pages>
        <priority>3</priority>
        <timezone>CEST</timezone>
        <year>2013</year>
        <month>7</month>
        <day>15</day>
        <hour>11</hour>
    </Metadataobject>
    and like this...
    <?xml version="1.0" encoding="UTF-8"?>
    <Metadataobject>
        <from>[email protected]</from>
        <jobname>P1_FR1330G006007_Kate_van der Vaart</jobname>
        <pages>2</pages>
        <priority>1</priority>
        <timezone>CEST</timezone>
        <year>2013</year>
        <month>7</month>
        <day>12</day>
        <hour>16</hour>
    </Metadataobject>
    I get many XML files like this. And I want them to be combined and shown like this:
    <?xml version="1.0" encoding="UTF-8"?>
    <Metadataobject>
        <job id="1">
        <from>[email protected]</from>
        <jobname>B3_IM09MBDUF</jobname>
        <pages>2</pages>
        <priority>3</priority>
        <timezone>CEST</timezone>
        <year>2013</year>
        <month>7</month>
        <day>15</day>
        <hour>11</hour>
        </job>
        <job id="1">
        <from>[email protected]</from>
        <jobname>P1_FR1330G006007_Kate_van der Vaart</jobname>
        <pages>2</pages>
        <priority>1</priority>
        <timezone>CEST</timezone>
        <year>2013</year>
        <month>7</month>
        <day>12</day>
        <hour>16</hour>
        </job>
    </Metadataobject>
    And finally the combined XML file converts in Excel sheet with column headings "Job ID", "From", "Job Name" and so on...
    Or there is another best way to get the same result...
    Thanks

    That is just an intermediary state to get to the excel version. Actually I get many small XML files (as shown above) from client and I want them all combined in an excel sheet with common column headings... like this...
    from
    jobname
      pages
    priority
    timezone
    year
    month
    day
    hour
    id
    [email protected]
    B3_IM09MBDUF
       2
    3
    CEST
    2013
    7
    15
    11
    1
    [email protected]
    B3_IM09MBDUF
       2
    3
    CEST
    2013
    7
    15
    11
    2
    Thanks for your response.

  • How to create a xml file from the jsp page?

    I'm a beginner of the develop xml,my question like this,
    there has a jsp page,some parameters in it,I wanna get the parameters and create a xml file,so,what parser method should I use?
    And how to create a new xml file,when the file haven't exist at first?
    pls give some code,thanks.

    a ggod link for u http://www.theserverside.com/resources/article.jsp?l=JSP-XML2

  • How to Save XML file in the same directory as the swf file automatically?

    Hi all,
    I'm really new here with flash and actionscript 3, so i might not make any sense, probably. Any input is greatly appreciated.
    So here's my problem, i'm trying to make a Top Score history for a flash game, which i load from an XML file. The problem comes to when i want to update the XML file. how do i do that automatically without prompting the user (ofcourse). I want it to be saved automatically to the same directory as the flash file.
    here's my code right now, but it prompts the user where it wants to be saved, which i don't want to happen:
    var xml:XML = <XML>
                        <topScoreList>
                        </topScoreList>
                  </XML>;
    for(var i:Number=0; i<10; i++)
         var Record:XML = <Record>
                             <score></score>
                             <playerName></playerName>
                        </Record>;
         Record.score.appendChild(topScores[i].toString()); //topScores[] -> class variable containing scores
         Record.playerName.appendChild(topNames[i].toString()); //topNames[] -> class variable containing names
         xml.topScoreList.appendChild(Record);
    var ba:ByteArray = new ByteArray();
    ba.writeUTFBytes(xml);
    var fr:FileReference = new FileReference();
    fr.save(ba, "topScoreList.xml");

    yeah that makes sense, actually - after reading a dozen more forums. It's really weird tho that flash doesn't have a Buffer writer, unlike other programming frameworks.
    But yeah, thanks. i'll start reading on flash.net.SharedObject, correct ? Thanks.
    Anyways, if anyone out there has a different input, will be greatly appreciated!!

Maybe you are looking for