Export Query SQL multi-linee in XML format and Import XML in SAP

Good morning
Someone know if is possible after Export Query SQL on OITT and ITT1 with thousands rows in XML with values already change thru the query.
Then import the XML without using loop in SAP with the above code vb.net
oDistinta = DirectCast(m_oCompany.GetBusinessObjectFromXML(xmlFile, 0), SAPbobsCOM.ProductTrees)
                Dim errCode As Integer = 0
                Dim strErrore As String = ""
                Dim iErrore As Integer = 0
                oDistinta.Browser.ReadXml(xmlFile, 0)
                errCode = oDistinta.Update
                m_oCompany.GetLastError(iErrore, strErrore)
                'on error
                If iErrore <> 0 Then
To make easy the program i post with 2 ProductTrees item. The 2 item already exist in OITT e ITT1.
When i update the 1st item is modify but the 2nd not change.
Here is the XML
<?xml version="1.0" encoding="UTF-16"?>
<BOM>
  <BO>
    <AdmInfo>
      <Object>66</Object>
      <Version>2</Version>
    </AdmInfo>
    <ProductTrees>
      <row>
        <TreeCode>V9998</TreeCode>
        <TreeType>iProductionTree</TreeType>
        <Quantity>1000.000000</Quantity>
        <U_SHI_MZDA>0</U_SHI_MZDA>
        <U_SHI_PUMA>0</U_SHI_PUMA>
        <U_SHI_PUUO>0</U_SHI_PUUO>
      </row>
    </ProductTrees>
    <ProductTrees_Lines>
      <row>
        <ItemCode>1047</ItemCode>
        <Quantity>5.000000</Quantity>
        <Warehouse>Mc</Warehouse>
        <Price>0.000000</Price>
        <Currency>
        </Currency>
        <IssueMethod>im_Backflush</IssueMethod>
        <Comment>
        </Comment>
        <ParentItem>V9998</ParentItem>
        <PriceList>2</PriceList>
        <DistributionRule>
        </DistributionRule>
        <U_IDE_POS>10</U_IDE_POS>
        <U_IDE_FASE>0</U_IDE_FASE>
        <U_IDE_OPER>10</U_IDE_OPER>
        <U_SHI_UndInv>N</U_SHI_UndInv>
        <U_SHI_Pri1>
        </U_SHI_Pri1>
        <U_SHI_Pri2>
        </U_SHI_Pri2>
        <U_SHI_Pri3>
        </U_SHI_Pri3>
        <U_SHI_Prgm>
        </U_SHI_Prgm>
        <U_SHI_Tim2>0.000000</U_SHI_Tim2>
        <U_SHI_Tim3>0.000000</U_SHI_Tim3>
        <U_SHI_DexNACQ>
        </U_SHI_DexNACQ>
        <U_SHI_BP>
        </U_SHI_BP>
        <U_SHI_PrcKit>0.000000</U_SHI_PrcKit>
        <U_SHI_ItmNACQ>
        </U_SHI_ItmNACQ>
        <U_SHI_LineOk>N</U_SHI_LineOk>
      </row>
    </ProductTrees_Lines>
    <ProductTrees>
      <row>
        <TreeCode>V9999</TreeCode>
        <TreeType>iProductionTree</TreeType>
        <Quantity>1000.000000</Quantity>
        <U_SHI_MZDA>0</U_SHI_MZDA>
        <U_SHI_PUMA>0</U_SHI_PUMA>
        <U_SHI_PUUO>0</U_SHI_PUUO>
      </row>
    </ProductTrees>
    <ProductTrees_Lines>
      <row>
        <ItemCode>1015</ItemCode>
        <Quantity>1000.000000</Quantity>
        <Warehouse>Mc</Warehouse>
        <Price>0.000000</Price>
        <Currency>
        </Currency>
        <IssueMethod>im_Backflush</IssueMethod>
        <Comment>
        </Comment>
        <ParentItem>V9999</ParentItem>
        <PriceList>5</PriceList>
        <DistributionRule>
        </DistributionRule>
        <U_IDE_POS>30</U_IDE_POS>
        <U_IDE_FASE>0</U_IDE_FASE>
        <U_IDE_OPER>30</U_IDE_OPER>
        <U_SHI_UndInv>N</U_SHI_UndInv>
        <U_SHI_Pri1>
        </U_SHI_Pri1>
        <U_SHI_Pri2>
        </U_SHI_Pri2>
        <U_SHI_Pri3>
        </U_SHI_Pri3>
        <U_SHI_Prgm>
        </U_SHI_Prgm>
        <U_SHI_Tim2>0.000000</U_SHI_Tim2>
        <U_SHI_Tim3>0.000000</U_SHI_Tim3>
        <U_SHI_DexNACQ>
        </U_SHI_DexNACQ>
        <U_SHI_BP>
        </U_SHI_BP>
        <U_SHI_PrcKit>0.000000</U_SHI_PrcKit>
        <U_SHI_ItmNACQ>
        </U_SHI_ItmNACQ>
        <U_SHI_LineOk>N</U_SHI_LineOk>
      </row>
    </ProductTrees_Lines>
  </BO>
</BOM>
Someone know the reason ?
Thanks in advance.
Regards

Hi Gabriele,
The issue is that the ReadXml method takes an index parameter which is the number of the object that you want to read from the XML data. In your code you are specifying index 0 which is the first product tree in your file so when you call the Update method this is the only record that will be updated. It is not possible to do a mass update using the DI API in this way, you must always load each object separately. You can use the GetXMLelementCount method of the Company object to find out how many product tree objects are in your file and then use the ReadXML method to load each one by incrementing the index parameter in a loop.
Kind Regards,
Owen

Similar Messages

  • How do you differentiate IDOC XML format and ordinary XML format

    how do you differentiate IDOC XML format and ordinary XML format since they are used by IDOC adapter and RFC adapter???

    Hi,
    Cremas Structure starts with Header and followed by Segments...
    Normally it begins like this
    <CREMAS03><IDOC BEGIN="1">
    The second node is Idoc in the header..
    Thanks
    Anju

  • Converting String To XML Format and send as attachment

    Hi
    My requirement is to convert String into XML Format and that XML File i have to send as an attachment
    can any one one give solution for this Problem.
    Thank you
    Venkatesh.K

    hi,
    i m filling the itab first and converting to xml
    itab contaning these data
    GS_PERSON-CUST_ID   = '3'.
    GS_PERSON-FIRSTNAME = 'Bill'.
    GS_PERSON-LASTNAME  = 'Gates'.
    APPEND GS_PERSON TO GT_PERSON.
    GS_PERSON-CUST_ID   = '4'.
    GS_PERSON-FIRSTNAME = 'Frodo'.
    GS_PERSON-LASTNAME  = 'Baggins'.
    APPEND GS_PERSON TO GT_PERSON.
    after conversion data is coming like that
    #<?xml version="1.0" encoding="utf-16"?>
    <CUSTOMERS>
      <item>
        <customer_id>0003</customer_id>
        <first_name>Bill</first_name>
        <last_name>Gates</last_name>
      </item>
      <item>
        <customer_id>0004</customer_id>
        <first_name>Frodo</first_name>
        <last_name>Baggins</last_name>
      </item>
    </CUSTOMERS>
    but errors are  1) # is coming at the first
                            2)for 'encoding="utf-16"?>', it is not coming perfectly, some other data (iso-8859-1) should come here
    can anybody plz solve it.
    regards,
    viki

  • Deliver a report in XML format and save it to local file system on the server

    We have OBIEE 10.1.3.4 on Redhat linux. We want to have generate a report in XML format and saved it to the server's file system. Did not realize this is s difficult task. Basically
    1) How to create a XML report? It is not listed in the output items of a layout template.
    2) How to deliver XML the report  to local file system. Look into the Delivery section of Admin page. FTP should be the best choice, but does that means that one need to install and run ftp server on the BI server box?
    Thanks

    Hi,
    Since I still have problems on this subject, I would like to share on how it progresses.
    Currently I have a problem of timeout in step "Truncate XML Schema" with the URL that I mentioned above.
    The exact error is the following : 7000 : null : com.sunopsis.sql.l: Oracle Data Integrator TimeOut : connection with URL [...]
    The connection test is still OK.
    I tried to increase the value in the user's pref but there's no change.

  • Unwanted Default Formatting with import XML

    I have a problem of unwanted default formatting with import XML. Under InDesign CS6, I  import XML with merge mode.
    One frame is difficult to apply with the placeholder, I should put the XML element A inside by hand. InDesign automatically applies the character style of the child element B to the following text in element A.
    I tried the steps of this article http://indesignsecrets.com/fixing-unwanted-default-formatting.php/comment-page-1#comment-5 62875
    But it doesn't work for me.
    Dose anyone have an idea? Thanks.

    Kasyan, I agree with you!
    So this is what i did in xslt.
    First I added the following namespace to the stylesheet.
    xmlns:file="http://www.jclark.com/xt/java/java.io.File"
    This is not supported by indesign, you have to do this with a parser. I used saxon to parse the xml.
    And this is the part for the existing file lookup.
    If the file exists the image is placed as a href, if it doesn't exist i put the name of the image between brackets. In this case we can see in which image doesn't exist.
    <xsl:choose>
         <xsl:when test="file:exists(file:new(string($imagefile)))">                                         
              <xsl:element name="Articleimage">
                   <xsl:attribute name="href">file://../images/<xsl:value-of select="Properties/Property[@field = 9]"/></xsl:attribute>
              </xsl:element>
          </xsl:when>
          <xsl:otherwise>
              <xsl:text>[</xsl:text><xsl:value-of select="Properties/Property[@field = 9]"/><xsl:text>]</xsl:text>
          </xsl:otherwise>
    </xsl:choose>
    I hope it helps for others.
    Good luck!
    Glen

  • Export to memory"  (bukrs) in one user exit and import to memory in other.

    I have to "export to memory"  (bukrs) in one user exit and import to memory in other.
    Does anyone has an example

    in one user exit:
    EXPORT field TO MEMORY ID 'Z_BUKRS'.
    in another user exit:
    IMPORT field FROM MEMORY ID 'Z_BUKRS'.
    what is the problem?

  • What is the most plain xml format to import clips and sequence into Premiere ?

    I want to create xml includes sequence and clips to import Premeire.
    In this case, I have a reference xml that is exported from premiere for finalcut pro. But this finalcut pro export format looks so complicated because has alot of property  that is belong to premiere pro. I tested by deleting some of them from xml and imported again, didn't effected anything.
    Here is the question, How can I create an xml which requires minimum property details for premiere sequence and clips ? Is there any reference better than FinalCut Pro export xml format ?

    Bruce from adobe replied that FCP Format is the best to import Premiere.
    So I read FCP Format Documentation from http://documentation.apple.com/en/finalcutpro/usermanual/index.html#chapter=97%26section=3 %26tasks=true

  • Data from table in xml Format and Inserting it into  Table

    Hi All
    I have table where xml data is stored in long format with xml tag know i have read the entire xml xoulmn which is xml tag and insert it into diffrent table can any suggest me the code
    Thanks & Regards

    I believe you are on the wrong forum. You want the XML DB forum.
    See:
    XML DB

  • How to export a video at a moderate certain format and size in premiere CC 2014: No Huge File Results!

    I have the latest version of Adobe Premiere, CC 2014 but whenever I want to render and export a video that is typically 70 megabytes in size I can't seem to always see how big the file will end up being for all the formats and I don't want to end up with a video larger than 250 to 300 megabytes in size just for the extremely best or highest quality even though I want the video to be well polished and in better quality than I usually get thee, These videos are usually imported as mp4. What file version of mp4 or otherwise would give me an originally imported video of 70 megabytes an output of no more than or around 300 megabytes or even less without compromsing video quality? I don't want a huge file size as I am uploading it to my YouTube channel via their web interface on another person's machine and they don't have Premiere and only has a DSL connection. So what video output settings should I use for a good quality video that isn't smaller than the original but the same size or a bit higher and not extremely large like MOVs and sometimes mp4s usually are depending on what you do to it and it is outputted.?

    Export
    Format: H.264
    Preset: YouTube (make sure this matches the dimensions of your sequence)
    You could further adjust the Target Bitrate but the preset is already setup for a good quality file for upload.
    You can also do further reading on Video Bitrates.

  • About the exporting and importing xml data file in the pdf form

    Hi all,
    I need help for importing xml data file in the pdf form. When I write some thing in the text field with fill color and typeface (font) and exported xml data using email button. When I imported that xml file in the same pdf file that is used for exporting the xml data then all the data are shown in the control but not color and font typeface. Anyone has suggestion for solving this problem. Please help me for solving this problem.
    Thank you
    Saroj Neupane

    Can you post a sample form and data to [email protected] and I will have a look.

  • Archive files are in XML format and not in the original format

    Hi all,
    I am using a receiver file adapter with archiving option. When I look at the archive files they are in the XML converted format and not in the original flat file format received. We would like to store these files for audit purpose and it doesnt make sense to store XML files. We are in SP04. Does a note need to be applied or any other extra configurations need to be done which I might have missed? Please advise.
    -Teresa

    Hi,
    >>>Wow, the note says its fixed in SP10
    but only the split is fixed not the XML messages in the archive I think (from the note)
    >>>Is there any alternative quick fix and I hate manual work
    create 2 new folders - connect one of them with the file adapter and the second one remains for archives
    in you normal destination folder for your files add a simple program that will check if there are any files and copy them to those two folders - this could be the fastes but obviously not the best solution I guess
    Regards,
    michal

  • Formating and calculating xml tag value

    I have an xml file that holds xml tag such as <weight>.55 kg</weight>
    I want to have two outputs:
    Output 1) Output to print: 0.55
    Output 2) Output to print 0.8 of the xml tag value (0.55 * 0.8) : 0.44
    I was able to get the Output 1) by using <?format-number:weight;'9G990D00'?>
    However, I can not get the Output2) as expected.
    If I put <?format-number:(weight)*0.8;'9G990D00'?>,
    I get the error message "Caused by: oracle.xdo.parser.v2.XPathException: Cannot convert .55 kg to number."
    Appreciate any help on how to solution for Output2)
    Edited by: user4697912 on Jun 22, 2010 1:23 AM
    Edited by: user4697912 on Jun 22, 2010 1:23 AM

    If that is the case then try using
    <?format-number:( substring-before(WEIGHT,'kg')*0.8);'9G990D00'?>

  • Osmf strobemediaplaybackair(mobile) XML format to import video

    I have downloaded the osmf trunk and import the strobemediaplayair in my flash builder. The xml file given in that is not a valid. I did not know much about XML. Please give me the format of xml used in the strobemediaplaybackair.   I have tried some xml but I think i am missing something.

    I'm guessing this is P2 footage, because you mention P2CMS.
    What you are doing is all wrong. Sorry to be blunt, but there are specific workflows for Panasonic P2, and what you are doing isn't it.
    XML files are for sequences and projects.
    Here is the proper P2 workflow: P2 Workflow with FCP 6
    Shane

  • Converting record albums to digital format and importing to iTunes

    I'm trying to convert record albums to digital format using a USB turntable and import the tracks to iTunes.  I have upgraded to the latest versions of software for the turntable and iTunes (10.5), but keep getting a message "unable to export to iTunes."  When iTunes opens up, it indicates that it is converting a temp file (e.g., temp6) rather than the individual tracks. 
    Confession:  I did something really dumb that may well have contributed to my problem.  The first time I started using the turntable, I recorded the album side; typed in the artist, album, and names of individual tracks; and clicked on the button to begin the export to iTunes.  When the iTunes windows opened up, things seemed to be working well.  I could see the individual tracks listed as they were being converted.  Then, a popup screen came up asking if I wanted to upgrade to the latest version of iTunes (I didn't have the 10.5 version at the time).  I temporarily lost control of my body (and mind) and clicked on yes.  This halted the conversion in process and I have never been able to get things working again, despite uninstalling and then reinstalling both the turntable software and iTunes software (including iTunes, Quicktime, Apple Software Update, Apple Mobile Device Support, Bonjour, and Apple Application Support).
    I would really appreciate some help with this!

    Do not use the "export to..." feature.  Let the conversion program create a file in an iTunes compatible format (such as WAV, AAC, or MP3) and then add that file to iTunes.

  • Acrobat 9 standard : form and import xml

    Hi all, is it possible to import xml data into a pdf form with acrobat 9 standart ?
    i don t have the 'form' menu.
    A friend can import xml under acrobat 8 standard, i tried to install version 8, but i can t find any form menu too....
    In the online document it seem to be possible using the form menu....
    Thanx

    For questions about Acrobat 9 Standard use the Acrobat forum.
    Adobe Reader can't import form data.

Maybe you are looking for

  • Database Error while running the query.

    Hi, While running the query in webi rich client i am having a "database error IES 10901 and WIS 10901" , it is showing that the data source name not found and default driver is not specified. I am trying to generate report from efashion universe whic

  • Sudden vast increase in broadband speed

    Hi, the last couple of days or so I've noticed my internet dropping off and when it happened again tonight, I ran a speed test, both on wholesale tester and speedtest.net, and instead of the usual 5meg that i normally get, im now getting 14megs. my e

  • Why does after effects cs5 not open in yosemite?

    i haven't used after effects in a year...but in that time i have installed Yosemite is this the cause of the app to not open?

  • Can you fade in and fade out the same layer in the same page state?

    I am simulating a lot of touch interactions, and have a hand object that moves over the simllated screen. I want to add small "taps" under the hands to show touch; I can see how its easy to fade IN an object (say a small circle) that represents the t

  • Issues with choppiness in image scrolling

    I am not super experienced in flash, but I'm wondering what the deal is.  The swf I export looks choppy as hell as it moves across the screen and I have it set to 120fps.  You can see it here: http://mattdaddy.net/client/animator_images.swf the fla i