How to append data in xml

I have below script which will create xml with data.
======================================================================
$xmlPath = "D:\Users\admin\Desktop\Report.xml"
$date = Get-Date -UFormat %m/%d/%Y
if ( ! ( Test-Path $xmlPath ) )
    # Create The XML
    $global:xmlWriter = New-Object System.XMl.XmlTextWriter($xmlPath,$Null)
    $global:xmlWriter.Formatting = "Indented"
    $global:xmlWriter.Indentation = "4"
    $global:xmlWriter.WriteStartDocument()
    $global:xmlWriter.WriteStartElement("Execution")
    $global:xmlWriter.WriteStartElement("ExecutedOn")
    $global:xmlWriter.WriteAttributeString("Date",$date)
    $global:xmlWriter.WriteStartElement("Environments")
    Foreach( $c in $cEnvironments)
        $global:xmlWriter.WriteStartElement($c.Environment)
        $global:xmlWriter.WriteAttributeString("Red",$c.Red)
        $global:xmlWriter.WriteAttributeString("Green",$c.Green)
        $global:xmlWriter.WriteAttributeString("Blue",$c.Blue)
        $global:xmlWriter.WriteEndElement() #end of $c.Environment
    $global:xmlWriter.WriteEndElement() #end Environments
    $global:xmlWriter.WriteStartElement("ClEnv")
    Foreach( $c1 in $clEnv)
        $global:xmlWriter.WriteStartElement($c1.Environment)
        $global:xmlWriter.WriteAttributeString("John",$c1.John)
        $global:xmlWriter.WriteAttributeString("Mike",$c1.Mike)
        $global:xmlWriter.WriteAttributeString("Alex",$c1.Alex)
        $global:xmlWriter.WriteEndElement() #end of $c1.Environment
    $global:xmlWriter.WriteEndElement() #end ExecutedOn
    $global:xmlWriter.WriteEndElement() #end execution
    $global:xmlWriter.WriteEndDocument() #end document
    $global:xmlWriter.Finalize
    $global:xmlWriter.Flush()
    $global:xmlWriter.Close()
else
    here I need to append the data in existing xml with the same above info but with different value
$cEnvironments $clEnv variables are array and having related data. Now I need to re run the script next day and check if the file is already exist. this is I am doing with if command. if it is already exist then using "else" I need to append the data
in existing xml with the same above info but with different values under section "Execution" like given below
======================================================================
<?xml version="1.0"?>
<?xml-stylesheet type='text/xsl' href='style.xsl'?>
<Execution>
    <ExecutionStarted Date="2/19/2014">
     <Environments1>
        <Colors Red="21" Blue="14" Green="18" />
    </Environments1>
    <Environments2>
        <Names John="21" Mike="14" Alex="18" />
    </Environments2>
</ExecutionStarted>
<ExecutionStarted Date="2/20/2014">
     <Environments1>
        <Colors Red="2" Blue="56" Green="76" />
        <Colors Cyan="31" Brown="32" Black="54" />
    </Environments1>
    <Environments2>
        <Names John="45" Mike="63" Alex="97" />
    </Environments2>
</ExecutionStarted>
</Execution>
Thanks.

I have below script which will create xml with data.
======================================================================
$xmlPath = "D:\Users\admin\Desktop\Report.xml"
$date = Get-Date -UFormat %m/%d/%Y
if ( ! ( Test-Path $xmlPath ) )
    # Create The XML
    $global:xmlWriter = New-Object System.XMl.XmlTextWriter($xmlPath,$Null)
    $global:xmlWriter.Formatting = "Indented"
    $global:xmlWriter.Indentation = "4"
    $global:xmlWriter.WriteStartDocument()
    $global:xmlWriter.WriteStartElement("Execution")
    $global:xmlWriter.WriteStartElement("ExecutedOn")
    $global:xmlWriter.WriteAttributeString("Date",$date)
    $global:xmlWriter.WriteStartElement("Environments")
    Foreach( $c in $cEnvironments)
        $global:xmlWriter.WriteStartElement($c.Environment)
        $global:xmlWriter.WriteAttributeString("Red",$c.Red)
        $global:xmlWriter.WriteAttributeString("Green",$c.Green)
        $global:xmlWriter.WriteAttributeString("Blue",$c.Blue)
        $global:xmlWriter.WriteEndElement() #end of $c.Environment
    $global:xmlWriter.WriteEndElement() #end Environments
    $global:xmlWriter.WriteStartElement("ClEnv")
    Foreach( $c1 in $clEnv)
        $global:xmlWriter.WriteStartElement($c1.Environment)
        $global:xmlWriter.WriteAttributeString("John",$c1.John)
        $global:xmlWriter.WriteAttributeString("Mike",$c1.Mike)
        $global:xmlWriter.WriteAttributeString("Alex",$c1.Alex)
        $global:xmlWriter.WriteEndElement() #end of $c1.Environment
    $global:xmlWriter.WriteEndElement() #end ExecutedOn
    $global:xmlWriter.WriteEndElement() #end execution
    $global:xmlWriter.WriteEndDocument() #end document
    $global:xmlWriter.Finalize
    $global:xmlWriter.Flush()
    $global:xmlWriter.Close()
else
    here I need to append the data in existing xml with the same above info but with different value
$cEnvironments $clEnv variables are array and having related data. Now I need to re run the script next day and check if the file is already exist. this is I am doing with if command. if it is already exist then using "else" I need to append the data in existing
xml with the same above info but with different values under section "Execution" like given below
======================================================================
<?xml version="1.0"?>
<?xml-stylesheet type='text/xsl' href='style.xsl'?>
<Execution>
    <ExecutionStarted Date="2/19/2014">
     <Environments1>
        <Colors Red="21" Blue="14" Green="18" />
    </Environments1>
    <Environments2>
        <Names John="21" Mike="14" Alex="18" />
    </Environments2>
</ExecutionStarted>
<ExecutionStarted Date="2/20/2014">
     <Environments1>
        <Colors Red="2" Blue="56" Green="76" />
        <Colors Cyan="31" Brown="32" Black="54" />
    </Environments1>
    <Environments2>
        <Names John="45" Mike="63" Alex="97" />
    </Environments2>
</ExecutionStarted>
</Execution>
Thanks.
In my opinion, you are creating difficulties when you treat the problem as [xml] objects.
A XML file is in fact, a TXT file, which can be interpreted in a specific way (XML way).
But to this current problem, you can view the XML file as a common TXT file, with 1 important requirement: the closing main node ( </Execution> in your example ) must be in its own line, and must be the last line in the file.
That said, you accomplish your task successfully, with this pretty much simple PS code:
$xmlFile='.\XML.xml'
$oldXmlText=@(gc $xmlFile)
$newXmlText=$oldXmlText[0..($oldXmlText.Count-2)]+
$inclusion+
$oldXmlText[-1]
Just compare this simplicity, with you original code's complexity.
The XML.xml file content can be this:
<?xml version="1.0"?>
<?xml-stylesheet type='text/xsl' href='style.xsl'?>
<Execution>
    <ExecutionStarted Date="1">
        <Environments1>
            <Colors Red="21" Yellow="14" Green="18" />
        </Environments1>
        <Environments2>
            <Names John="21" Mike="14" Alex="18" />
        </Environments2>
    </ExecutionStarted>
</Execution>
Notice the very last line.
And the variable $inclusion can be this:
$inclusion=@'
   <ExecutionStarted Date="2">
        <Environments3>
            <Names blue="21" black="14" cyan="18" />
        </Environments3>
   </ExecutionStarted>
My Friend Come See How Abject Repugnant Politics... r.

Similar Messages

  • How to add data in xml file

    Hi ALL
    I want to add new fields on seeded EBS page to store their values in hr_api_transaction table whoch contain information of other fields on that page which are seeded
    but that table has one column which stores xml file and that xml file has all information about that page's fields
    how can I store my custom fields values in that xml file ?

    Hi,
    As Andy said,  add data to an xml file is overwriting, if you mean append data to xml file, please look this article:
    http://codesamplez.com/programming/linq-to-xml-tutorial, Since this issue is more related to ASP.net, you could also ask this issue in asp.net forum:
    http://forums.asp.net/
    Best Regards,
    Jambor
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • How to extract data from XML file with JavaScript

    HI All
    I am new to this group.
    Can anybody help me regarding XML.
    I want to know How to extract data from XML file with JavaScript.
    And also how to use API for XML
    regards
    Nagaraju

    This is a Java forum.
    JavaScript is something entirely different than Java, even though the names are similar.
    Try another website with forums about JavaScript.
    For example here: http://www.webdeveloper.com/forum/forumdisplay.php?s=&forumid=3

  • Appending Data in XML File using JAXB

    I need to write the 50,000 records into XML file. But at a time i need to write only 1000 records into XML. How do i append the data into XML using JAXB.

    I have tried but the data is written in the following way:
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <Users xmlns="http://www.yyyy.com/umc/importer/jaxb">
    <User id="101" xmlns="">
    <username>gjhs</username>
    <password>hdfhhdf</password>
    <role>df</role>
    <email>sdd</email>
    <phone>sdfdf</phone>
    <description>shkl</description>
    <property name="ernnker" value="hkdfhk"/>
    </User>
    </Users>
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <Users xmlns="http://www.yyyy.com/umc/importer/jaxb">
    <User id="101" xmlns="">
    <username>gjhs</username>
    <password>hdfhhdf</password>
    <role>df</role>
    <email>sdd</email>
    <phone>sdfdf</phone>
    <description>shkl</description>
    <property name="ernnker" value="hkdfhk"/>
    </User>
    </Users>
    If i can eliminate the following lines from the above files then my job is done:
    </Users>
    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <Users xmlns="http://www.yyyy.com/umc/importer/jaxb">

  • Datapump : How to append data in an existing table

    Hello Everyone,
    We are new to Datapump.
    We try to extract data from one user/schema and to append it into another user/schema.
    First we tried Tt use the parameter table_exists_action=append during the importation but we receive this error (but the rows are appended):
    ORA-39152: Table "XXXXX"."YYYYY_ZZZ" exists. Data will be appended to existing table but all dependent metadata will be skipped due to table_exists_action of append
    Which I don't expect since the utility have been told to, indeed, append data.
    Next we tried to use CONTENT=DATA_ONLY on exportation and importation but the importation never end.
    How can we append data into a table's user/schema without having an error?
    Best regards.
    Carl

    IGNORE=Y during the import.it does the same operation. if the table already exists,it ignores and proceed with importing/appending data to the tables. same way, they do have indexes=n and constraints=n option.
    both export/import have equivalent options for fitering to our requirement and datapump has one step above classic import in which you can filter upto metadata object as well.

  • How to append data in array

    I use three read waveform nodes to read data from three channels of
    oscilloscope. The data of each channel are 1D array, and I use build
    array node to change them into 2D array. It can work well now.
    When I want to continuously reading data, I put the read waveform nodes
    and build array node into a while loop structure(a timer controls the
    time when to stop). That means every time, the program calls read
    waveform nodes and then changes them into 2D array. The problem is:after
    each loop, the data stored in the 2D array are overwrited. So, at last,
    I can only get the last loop data.
    I want to append the data into the 2D array, but I do not know how to
    implement? I have tried put the build array outside the while loop,
    unfortunatel
    y, it does not work.
    Any advice would be appreciated.
    Sent via Deja.com http://www.deja.com/
    Before you buy.

    The shift register is a built in way to carry data forward from one
    iteration of a loop to the next iteration.. Anything that you feed into the
    right shift register appears a data at the beginning of the next loop. You
    already have Build Array to combine three 1D array Elements into a single 2D
    array. Use another Build Array function to combine the current 2D array
    with the previous 2D array to create a combined array. To do this, you must
    change the input mode of the Build Array function to Array (not Element).
    This will concatenate the arrays and make the continuous data that you are
    after.
    The only other hidden step is that you must use Initialize Array to feed a
    blank, 2D array into the left shift register to clear any leftover data.
    Michael Munroe Mailto:[email protected]
    A Better Complete Development Engineering Firm
    San Mateo, CA 94403 http://www.abcdefirm.com
    [email protected] wrote:
    > Because I am very new to Labview and in fact, English is not my native
    > language, I can not understand the sentence that "combine the current
    > reading with the previous reading from the left shift register and save
    > it back to the right shift register" means.
    >
    > Now, I want to descript my question in a simple way:
    > In a while loop, I use a build array node to build three 1D arrays into
    > one 2D array. For each time when while loop repeats, the value of these
    > 1D arrays change, I want to append the new data to the previous ones.
    > But in my program, the data in the build array are overrided after the
    > while loop repeating.
    > So, How to append the data instead of overriding them in the while loop
    > structure?
    >
    > Thanks a lot!
    >
    > zhljh
    >
    > In article <[email protected]>,
    > Michael Munroe wrote:
    > > You need to combine the build array function with the shift register.
    > Pop
    > > up on the edge of the loop and Add Shift Register. You can combine the
    > > current reading with the previous reading from the left shift register
    > and
    > > save it back to the right shift register.
    > > --
    > > Michael Munroe Mailto:[email protected]
    > > A Better Complete Development Engineering Firm
    > > San Mateo, CA 94403 http://www.abcdefirm.com
    > >
    > > [email protected] wrote:
    > >
    > > > I use three read waveform nodes to read data from three channels of
    > > > oscilloscope. The data of each channel are 1D array, and I use build
    > > > array node to change them into 2D array. It can work well now.
    > > > When I want to continuously reading data, I put the read waveform
    > nodes
    > > > and build array node into a while loop structure(a timer controls
    > the
    > > > time when to stop). That means every time, the program calls read
    > > > waveform nodes and then changes them into 2D array. The problem
    > is:after
    > > > each loop, the data stored in the 2D array are overwrited. So, at
    > last,
    > > > I can only get the last loop data.
    > > > I want to append the data into the 2D array, but I do not know how
    > to
    > > > implement? I have tried put the build array outside the while loop,
    > > > unfortunately, it does not work.
    > > > Any advice would be appreciated.
    > > >
    > > > Sent via Deja.com http://www.deja.com/
    > > > Before you buy.
    > >
    > >
    >
    > Sent via Deja.com http://www.deja.com/
    > Before you buy.
    Michael Munroe, ABCDEF
    Certified LabVIEW Developer, MCP
    Find and fix bad VI Properties with Property Inspector

  • How to append data in same log after start and stop signal express

    how can i append my data to the same log file after starting and stopping the signal express ? Is there some option to do this. After start/stop it always makes a new log file. How can append datat to the same log file. 
    Thanks in advance. 
    Munir

    Hello mbhatti,
    I founded a KB which seems do describe the way to solve your problem.
    Appending Data to the Same File when Logging in LabVIEW SignalExpress :
    http://digital.ni.com/public.nsf/allkb/C38AEE499D5CC8C6862572CF006875D2?OpenDocument
    I hiope this will help you
    Regards
    Florian Abry
    Application Engineer Group Leader
    NI Germany

  • How to append data  runtime in Table in MIDlet

    Hi Friends,
    i am having 2 queries..
    1st:: How can i append data runtime in table in MIDlet ( like web )which are coming from Database.
    2: requirement is that 1st row of table should for headings like StartDate,EndDate,Resources and Status.
    From the 2nd row ,Columns for runtime data.(Like any Table how u all got my query).
    Plz send me reply as early as possible.
    Waiting for reply
    Best regards
    karan

    Presently you cannot use AJAX kind of stuffs in J2ME.
    If you want to achieve the functionality better to look at articles wriiten on writing custom items in J2ME. That will help you achieve the kind of requirement that you are expecting.
    ~Mohan

  • How to populate data from XML to SQLserver 2008

    Hi 
    I have following XML file data. I need to create table in sql sever and load the data. I dont know how to read and load the file located at C:Drive.
    Please kindly help me on loading the data into table
    This is what I see in the file located on C drive - invoiceXML: 
    <?xml version="1.0" encoding="utf-8"?>
    <CLinv xmlns="http://www.sdfsfdfsfd.com">
      <billCom xmlns="">billCom1</billCom>
      <remittance xmlns="">
        <remCom>remCom1</remCom>
      </remittance>
      <summary xmlns="">
        <title>title1</title>
        <TBAmt>1</TBAmt>
        <totalNC>1</totalNC>
        <accountAging>
          <past3DAm>1</past3DAm>
          <tPDe>1</tPDe>
        </accountAging>
        <items>
          <item>
            <itNo>1</itNo>
            <NC>1</NC>
          </item>
          <item>
            <itNo>23</itNo>>
            <NC>23</NC>
          </item>
          <item>
            <itNo>34</itNo>
            <NC>34</NC>
          </item>
        </items>
      </summary>
      <GrpDet xmlns="">
        <detailGrouping>
          <grouping>grouping1</grouping>
          <details>
            <detail>
              <CNo>CNo1</CNo>
              <Namtt>1</Namtt>
            </detail>
            <detail>
              <CNo>CNo2</CNo>
              <Namtt>23</Namtt>
            </detail>
            <detail>
              <CNo>CNo3</CNo>
              <Namtt>34</Namtt>
            </detail>
          </details>
        </detailGrouping>
        <detailGrouping>
          <grouping>grouping2</grouping>
          <details>
            <detail>
              <CNo>CNo4</CNo>
              <Namtt>0.9</Namtt>
            </detail>
            <detail>
              <CNo>CNo5</CNo>
              <Namtt>1.1</Namtt>
            </detail>
            <detail>
              <CNo>CNo6</CNo>
              <Namtt>23</Namtt>
            </detail>
          </details>
        </detailGrouping>
        <detailGrouping>
          <grouping>grouping3</grouping>
          <details>
            <detail>
              <CNo>CNo7</CNo>
              <Namtt>34</Namtt>
            </detail>
            <detail>
              <CNo>CNo8</CNo>
              <Namtt>0.8</Namtt>
            </detail>
            <detail>
              <CNo>CNo9</CNo>
              <Namtt>1.2</Namtt>
            </detail>
          </details>
        </detailGrouping>
      </GrpDet>
    </CLinv>

    Sorry This is the correct Data:
    <?xml version="1.0" encoding="utf-8"?>
    <CLinv xmlns="http://www.sdfsfdfsfd.com">
      <billCom xmlns="">billCom1</billCom>
      <remittance xmlns="">
        <remCom>remCom1</remCom>
      </remittance>
      <summary xmlns="">
        <title>title1</title>
        <TBAmt>1</TBAmt>
        <totalNC>1</totalNC>
        <accountAging>
          <past3DAm>1</past3DAm>
          <tPDe>1</tPDe>
        </accountAging>
        <items>
          <item>
            <itNo>1</itNo>
            <NC>1</NC>
          </item>
          <item>
            <itNo>23</itNo>>
            <NC>23</NC>
          </item>
          <item>
            <itNo>34</itNo>
            <NC>34</NC>
          </item>
        </items>
      </summary>
      <GrpDet xmlns="">
        <detailGrouping>
          <grouping>grouping1</grouping>
          <details>
            <detail>
              <CNo>CNo1</CNo>
              <Namtt>1</Namtt>
            </detail>
            <detail>
              <CNo>CNo2</CNo>
              <Namtt>23</Namtt>
            </detail>
            <detail>
              <CNo>CNo3</CNo>
              <Namtt>34</Namtt>
            </detail>
          </details>
        </detailGrouping>
        <detailGrouping>
          <grouping>grouping2</grouping>
          <details>
            <detail>
              <CNo>CNo4</CNo>
              <Namtt>0.9</Namtt>
            </detail>
            <detail>
              <CNo>CNo5</CNo>
              <Namtt>1.1</Namtt>
            </detail>
            <detail>
              <CNo>CNo6</CNo>
              <Namtt>23</Namtt>
            </detail>
          </details>
        </detailGrouping>
        <detailGrouping>
          <grouping>grouping3</grouping>
          <details>
            <detail>
              <CNo>CNo7</CNo>
              <Namtt>34</Namtt>
            </detail>
            <detail>
              <CNo>CNo8</CNo>
              <Namtt>0.8</Namtt>
            </detail>
            <detail>
              <CNo>CNo9</CNo>
              <Namtt>1.2</Namtt>
            </detail>
          </details>
        </detailGrouping>
      </GrpDet>
    </CLinv>

  • How to write data to xml file?

    Hi,
    I have done a project which read data from a web then write in log file.
    Now i want to write data in xml file.
    how to write?
    i read some java and xml tutorial, quite quite difficult.
    Who can give a simple example with some comments?
    If you also give some tips on learning java web services, i will be very appreciated.
    Thanks
    Yang Bin

    Choose Xerces2.4 to serialize the DOM object is an option.
    javac XercesTest.java -classpath xmlParserAPIs.jar;xercesImpl.jar;.
    java -classpath xmlParserAPIs.jar;xercesImpl.jar;. XercesTest test.xml
    below is the source file: XercesTest.java
    //JAXP
    import javax.xml.parsers.*;
    import org.w3c.dom.*;
    //APACHE SERIALIZE FUNCTION
    import org.apache.xml.serialize.*;
    class XercesTest
    public static void main(String[] args) throws Exception
    DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
    DocumentBuilder builder = factory.newDocumentBuilder();
    Document doc = builder.parse( new File( args[0] ) );
    File f = new File( "copy_of_"+ args[0] );
    OutputFormat format = new OutputFormat("xml","UTF-8",true ) ;
    FileOutputStream fout = new FileOutputStream( f );
    XMLSerializer ser = new XMLSerializer(fout, format );
    ser.serialize( doc );
    hope it's helpful
    land

  • How to write data into xml through web service

    Hi,
      I have a requirement to write the data into xml through a web service .send me related links and sample code if any.

    hi kiran,
      write the data into xml : We need suitable set of java Beans for handling WebService Data.
       However, there are cases when you may prefer an alternate mapping, or when there just isn't a well-defined mapping for your particular schema construct (xsd:choice is a common example). For these cases, IBM® WebSphere® has introduced a new feature called Custom Data Binding that allows you to integrate alternate data binding technologies like JAX-B, EMF/SDO and XML beans, as well to define your own XML schema to Java mappings. This article provides an overview of the technology and how you can get started integrating it into your application.
    GO THru THis Links :
    http://www-128.ibm.com/developerworks/websphere/library/
    techarticles/0601_gallardo/0601_gallardo.html.
    Hope It Helps.
    Thanks
    Varun CN

  • How to extract data from xml and insert into Oracle table

    Hi,
    I have a large xml file. which will have hundreds of the following transaction tags having column names and there values.
    There is a table one of the schema with coulums "actualCostRate","billRate"....etc.
    I need to extract the values of these columns and insert into the table
    <Transaction actualCostRate="0" billRate="0" chargeable="1" clientID="NikuUK" chargeCode="LCOCD1" externalID="L-RESCODE_UK1-PROJ_UK_CNT_GBP-37289-8" importStatus="N" projectID="TESTPROJ" resourceID="admin" transactionDate="2002-02-12" transactionType="L" units="11" taskID="5017601" inputTypeCode="SALES" groupId="123" voucherNumber="ABCVDD" transactionClass="ABCD"/>
    <Transaction actualCostRate="0" billRate="0" chargeable="1" clientID="NikuEU" chargeCode="LCOCD1" externalID="L-RESCODE_US1-PROJ_EU_STD2-37291-4" importStatus="N" projectID="TESTPROJ" resourceID="admin" transactionDate="2002-02-04" transactionType="L" units="4" taskID="5017601" inputTypeCode="SALES" groupId="124" voucherNumber="EEE222" transactionClass="DEFG"/>

    Re: Insert from XML to relational table
    http://www.google.ae/search?hl=ar&q=extract+data+from+xml+and+insert+into+Oracle+table+&btnG=%D8%A8%D8%AD%D8%AB+Google&meta=

  • How to append data from different import files?

    Dear experts,
    The customer is having different applications running that will output imports files BPC needs at a different time of process. Is it possible to append data which already exist in BPC from import?
    eg. BPC already has a record
    Factory1, Actual, 2008.OCT, Movement1, 30
    import file-
    Factory1, Actual, 2008.OCT, Movement1, 100
    and I need to add them up to become 130.
    Looks like regular import will only replace the original record by the new imported value. I'm still trying...
    Thanks a lot,
    Jim Hsu

    I do not think there is a way to use a standard import package to perform this action.  Typically when you are importing, you are saying this is the new value.  Not increment/decrement the value. 
    I have never had to implement a solution for a problem like this.  However, I would write a custom SSIS package that would extract the BPC data for the same dimensionality being imported and append it with the import file, then import the combined file.  Values sharing the same dimensionality in the same import file are aggregated on the actual import.
    SO your input file has 30, the export gets 100, the combined file has both and the actual value imported would be 130.
    That would be the approach I would take, but others might have more experience in different areas.

  • How to prevent data-sources.xml from being included in EAR

    I cannot get rid of the data-sources.xml file in my EAR file in the meta-inf folder.
    Deselecting the "Bundle Default data-sources.xml during deployment" in my preferences didn't have any effect. I also tried shutting down/restarting JDeveloper just in case it was cached.
    I also tried adding an exclude filter for data-sources.xml in my deploy profile for both Web files and WEB-INF/classes.

    The way I resolved this was to create the data-sources.xml, right click it, select Properties then uncheck Auto-update data sources.xml. That way it stays empty (hopefully).

  • How to fetch data from XML and store it in internal table

    Hi All,
    Can anyone help me out, in fetching data from xml and store it in an internal table. Is there any standard function module is there?
    Regards,
    Karthick

    to do this you can either develop a XSLT program and use it with CALL TRNSFORMATION key word to tranform the XML into itab .
    (search the ABAP General forum, i have posted few samples)
    or simply use the following FM which converts your XML into a itab of name value pair (name would holw the element name and value would hold the value of the element) which you can then loop and read it to your itb.
    data:             xmldata type xstring .
    data: result_xml type standard table of smum_xmltb .
    data: return type standard table of bapiret2 .
    CALL FUNCTION 'SMUM_XML_PARSE'
      EXPORTING
        xml_input       = xmldata
      TABLES
        xml_table       = result_xml
        return          = return .
    Regards
    Raja

Maybe you are looking for