Home > Default > Problem in extracting data

Problem in extracting data

November 30Hits:0
Advertisement
Hi All
i am getting problem while extracting data.
XML is .
<po:PurchaseOrder xmlns:po="http://www.oracle.com/PO.xsd"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.oracle.com/PO.xsd
http://www.oracle.com/PO.xsd">
<PONum>1005</PONum>
     <Company>Oracle</Company>
<Item>
<Part>9i Doc Set</Part>
<Price>2550</Price>
</Item>
<Item>
<Part>8i Doc Set</Part>
<Price>350</Price>
</Item>
</po:PurchaseOrder>
and i am writing SELECT query as
select p.extract('/(PurchaseOrder/Company)').getStringVal() from po_tab2 p
then i get blank rows.
SQL> select p.extract('/PurchaseOrder/Company').getStringVal() from po_tab2 p;
P.EXTRACT('/PURCHASEORDER/COMPANY').GETSTRINGVAL()
6 rows selected.
but if i use only root element in xpath then it displays result with xml data.
SQL> select p.extract('/PurchaseOrder').getStringVal() from po_tab2 p;
P.EXTRACT('/PURCHASEORDER').GETSTRINGVAL()
<po:PurchaseOrder xmlns:po="http://www.oracle.com/PO.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchem
a-instance" xsi:schemaLocation="http://www.oracle.com/PO.xsd http://www.oracle.com/PO.xsd">
<PONum>1001</PONum>
<Company>Oracle</Company>
<Item>
<Part>9i Doc Set</Part>
<Price>2550</Price>
</Item>
<Item>
<Part>8i Doc Set</Part>
<Price>350</Price>
how can i extract data from child nodes.

Answers

seems like problem with the namespace.
pls add the third argument to the extract function i.e the namespace.
select p.extract('/PurchaseOrder/Company', 'target namespace').getStringVal() from po_tab2 p;

Read other 4 answers

Tags:

Related Articles

  • Problem in extracting dataNovember 30

    Hi All i am getting problem while extracting data. XML is . <po:PurchaseOrder xmlns:po="http://www.oracle.com/PO.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.oracle.com/PO.xsd http:/

  • Problem with extract data from R/3 to BWOctober 11

    I want extract data from R/3 system.the problem is when I run the infopackage,I can see the status is yellow In the Monitor and the data can't extract to BW.but in the source system,the job of extracting data has been finished. (use the Tcode: WE02)t

  • I have a problem to  extract data from oracle dump file (.dmp) using oracle database or any other tools.October 11

    There is IMP utility which provides me data as graphical way. But i need extract data in such a way so that i could able to use in my application. thanks, mohanHi, EdStevens Actually I was using SQL Developer. Sorry for the wrong define question. Now

  • Problem when extracting data from R/3 to BINovember 30

    Hi Experts, I am facing a strange problem. While i am extracting data from R/3 yo BI. One Infopackage is running successfully and i can see the data at Bi side. But while I am running another infopackage for another data source it is taking long time

  • Problems to extract data from 0HR_PY_1November 30

    Hi Experts, I'm using BW v.7 to extract data from standard data source 0HR_PY_1 of SAP-ECC, with delta update. When I try to extract the data job finishes with error (red status) and all data-packages have error message ABORT in customer routine 9998

  • Problems in extracting data from r/3November 30

    Hi Guys I am extracting data from r/3(QA) to BW(QA), into an ODS. Now, my previous load failed but i saw from RSMO that the load had more than 4 million records. I am scheduled the load again. And in monitor(RSMO) it says: (yellow symbol) 17:24:50 (

  • Problem in extracting data from source systemNovember 30

    HI    I am comparing source system and data in bW for a particular datasource.In this process in source system transaction RSA3 when i am trying to extract data its not showing the exact count.I couldnt able to understand the setting options like Dat

  • Problem in extracting data from Z totals table (special Ledger)October 11

    Hi Gurus, I am in a task of pulling in specific fields from the Z Totals Table of Special Purpose Ledger into the cube. We only need totals records and do not need line items. In SBIW, i have generated the transfer structure and datasource for totals

  • Problem to extract data using DS 2LIS_11_VAHDR & 2LIS_11_VAITMNovember 30

    Hello Experts, my requirement is to extract the SD sales Item & sales header data int BI.  while executing the Reports in BI  I find some incosistencies in data Ex:  for for some Sales organizations         0CRM_NUMDOC = 17 and the corresponding   0N

  • Problem in extracting data from another BW serverNovember 30

    Hello Experts I have two BW servers in landscape. One is used as stagins server and second server exctracts data form this server and is used as reporting server. I can see data in DSOs in stagins server, also checked export datasources in RSA3 in st

Copyright (C) 2019 wisumpire.com, All Rights Reserved. webmaster#wisumpire.com 14 q. 0.722 s.