Need assistance to migrate data from XML to oracle table.

Hey Odie,

Im trying to insert data from an xml file into a table.

My XML file is as follows.

<? XML version = "1.0" encoding = "UTF-8" standalone = 'yes' ?>

- < TransferXML >

< BatchName > HJ69240 < / BatchName >

< BatchStatus > Park < / BatchStatus >

- < SubBatch >

< SubBatchName > UQ80288 < / SubBatchName >

< SubBatchStatus > project < / SubBatchStatus >

- < SubBatchDetail >

< Ingredient > I3308 < / > of theingredient

< DispensedQty > 0,0 < / DispensedQty >

< MDispensedQty > 4.0 < / MDispensedQty >

< / SubBatchDetail >

- < SubBatchDetail >

< Ingredient > I3261 < / > of theingredient

< DispensedQty > 0,0 < / DispensedQty >

< MDispensedQty > 3.5 < / MDispensedQty >

< / SubBatchDetail >

- < SubBatchDetail >

< Ingredient > I3235 < / > of theingredient

< DispensedQty > 0,0 < / DispensedQty >

< MDispensedQty > 0,5 < / MDispensedQty >

< / SubBatchDetail >

- < SubBatchDetail >

< Ingredient > I3142 < / > of theingredient

< DispensedQty > 0,0 < / DispensedQty >

< MDispensedQty > 0,2 < / MDispensedQty >

< / SubBatchDetail >

</SubBatch>

- < SubBatch >

< SubBatchName > ZB97913 < / SubBatchName >

< SubBatchStatus > incomplete < / SubBatchStatus >

- < SubBatchDetail >

< Ingredient > I3309 < / > of theingredient

< DispensedQty > 0,75 < / DispensedQty >

< MDispensedQty > 0,0 < / MDispensedQty >

< / SubBatchDetail >

- < SubBatchDetail >

< Ingredient > I3436 < / > of theingredient

< DispensedQty > 0,0 < / DispensedQty >

< MDispensedQty > 0,05 < / MDispensedQty >

< / SubBatchDetail >

</SubBatch>

<Final>false</Final>

< / TransferXML >



With the help of your previous posts I've migrated data from this xml file in a table that works perfectly well. But these data repeats instead of giving 6 lines that his return 12 lines guide please.


CREATE TABLE XXBATCH AS

SELECT A.BatchName, A.BatchStatus, B.SubBatchName, B.SubBatchStatus, C.Ingredient, C.DispensedQty, C.MDispensedQty, A.FINAL

OF (XMLTable ('/ TransferXML'))

from xmltype)

BFILENAME('APPS_DATA_FILE_DIR','HJ69240.) XML')

nls_charset_id ('AL32UTF8')

) COLUMNS

BatchName VARCHAR2 path (99) "BatchName.

, Path of the BatchStatus VARCHAR2 (999) "BatchStatus.

Path VARCHAR2 (99) final 'Final')),

(XMLTable ('/ TransferXML/SubBatch '))

from xmltype)

BFILENAME('APPS_DATA_FILE_DIR','HJ69240.) XML')

nls_charset_id ('AL32UTF8')

) COLUMNS

Path of SubBatchName VARCHAR2 (99) "SubBatch/SubBatchName".

, Path of the SubBatchStatus VARCHAR2 (99) "SubBatch/SubBatchStatus".

(B)

(XMLTable ('/ TransferXML/SubBatch/SubBatchDetail '))

from xmltype)

BFILENAME('APPS_DATA_FILE_DIR','HJ69240.) XML')

nls_charset_id ('AL32UTF8')

) COLUMNS

Path of the ingredient VARCHAR2 (99) SubBatchDetail/ingredient"."

, Path of the DispensedQty VARCHAR2 (99) "SubBatchDetail/DispensedQty".

, Path of the MDispensedQty VARCHAR2 (99) "SubBatchDetail/MDispensedQty".

(C)

I didn't test your query, but apparently it's because you have access to the same file three times instead of spend one XMLTable to another correlated nested groups.

Better, this should work:

SELECT A.BatchName

A.BatchStatus

B.SubBatchName

B.SubBatchStatus

C.Ingredient

C.DispensedQty

C.MDispensedQty

A.FINAL

FROM XMLTable ('/ TransferXML')

PASSAGE xmltype (bfilename('TEST_DIR','HJ69240.xml'), nls_charset_id ('AL32UTF8'))

Path of COLUMNS BatchName VARCHAR2 (99) "BatchName.

, Path of the BatchStatus VARCHAR2 (999) "BatchStatus.

, Path VARCHAR2 (99) final "Final."

, Path of XMLTYPE «SubBatch» SubBatchList

) AT

, XMLTable ('/ SubBatch')

PASSAGE SubBatchList

Path of COLUMNS SubBatchName VARCHAR2 (99) "SubBatchName".

, Path of the SubBatchStatus VARCHAR2 (99) "SubBatchStatus".

, Path of XMLTYPE «SubBatchDetail» SubBatchDetailList

) B

, XMLTable ('/ SubBatchDetail')

PASSAGE SubBatchDetailList

Path VARCHAR2 (99) ingredient of COLUMNS "Ingredient."

, Path of the DispensedQty VARCHAR2 (99) "DispensedQty".

, Path of the MDispensedQty VARCHAR2 (99) "MDispensedQty".

) C

;

Post edited by: odie_63

Tags: Oracle Development

Similar Questions

  • Import/insert data from XML in Oracle database tables?

    Hello. (I use 10.1.3.3.0 JDeveloper and Oracle 10 g)

    I was able to export the data of one of my tables in the database using a View object and .writeXML.

    Now, I want to take an xml file that is formatted just like what is spit out by the writeXML and put this info in my database table. I followed the examples online, and have tried to use .readXML as follows:

    Element = XMLDoc.getDocumentElement ();

    vo.readXML (element,-1);

    I know that it's the kind of work, because at first, I got an error message that one of the required attributes was missing. So, I added this attribute in my xml file and run my code. No errors. But, I checked my database, and new records have been added.

    Is there something I did wrong? Or is it maybe something I left out? I also noticed that there are several versions of readXML as readFromXML. Which should I use and how?

    Thank you.

    Hello

    Example of work is completely: http://kuba.zilp.pl/?id=461

    Kuba

  • I used the migration assistant to transfer data from my pc windows for my macbook pro, and it erased all my data. Is he here to retrieve these data

    I used the migration assistant to transfer data from my laptop to windows xp for my macbook pro OS X Yosemite 10.10.5 version and she erased all the data on my mac iTunes i.e., photos, documents, games, etc. Is it possible to recover these data or take it back to a State of pre migration? If not can I erase it and reload the software from scratch?

    Thank you

    Dave has

    You have a backup of Mac before moving the data from the PC?

  • install Oracle 12 c and migrate data from 9i to 12 c on Solaris

    HI: this is a primary control to check IAM step by step.  I need to migrate the server Oracle 9i (Solaris) to 12 c (Solaris) to the customer request. I have the instruction of installation YES from the team, the draft plan is:

    1. install Oracle 12 c binary on Solaris Server

    2 exp/imp, method to move data to 12 c 9i.

    Should I create a database "empty" by script until I use the exp/imp method to migrate data from 9i?  Or, is it better to use the option 'create the single database instance' in YES during the installation of 12 c, then exp/imp?  How about the "plug-in database" or the "CBD/PDB' concept to 12 c?  It's still new and I am not master familiar with it, that I have to use all "CBD/PDB' 12 c or not?

    Any problem that I need to know?

    Thank you very much!

    You have your point of disagreement, but it is the best approach of guys Upgrade Oracle, google for Mike Dietrich blogs on updates. And your concern that make upgrades does not allow you to practice, well, you could easily make a few tests on my upgrade on a test environment, I really don't agree with your point here...

    Sorry - but I agree with the ground.

    Anyone who still uses 9i has some questions SERIOUS architecture dealing with totally outside the DB and data. There is just too much features auxiliary available (e.g., ASM, GRID, EM) which did NOT exist in 9i or substantially changed.

    It is also a non-starter, IMHO, not to recommend as an upgrade to 11g without even knowing the 9i version that uses OP. A direct upgrade to 11g is NOT possible since the first versions of 9i. So if such a version uses OP they couldn't make a direct upgrade anyway. They will need first to upgrade to the last version 9i and then level it to 11g. Then, they should adapt to 12 c.

    Then you must take account of the need for BACKUP:

    1. PRIOR to starting to do something

    2. AFTER the upgrade to 9.2.04

    3. AFTER the upgrade to 11 g

    4. AFTER the upgrade to 12 c

    Compare that to the approach of that ground is recommended to use export/import. There is NO need to save the source DB at all since the process will NOT change. Simply a backup after upgrading to 12 c.

  • What is the best strategy to migrate data from Windows to one Mac to another? I use Parallels Desktop to run Windows on my current Mac but want to use Bootcamp on my new.

    What is the best strategy to migrate data from Windows to one Mac to another? I use Parallels Desktop to run Windows on my current Mac but want to use Bootcamp on my new.

    If it is only the data (not apps) I use Dropbox. It turned out to be the best way to move things between the side Mac and the bootcamped Windows of my iMac side. I don't see why it would not work to move data from a virtual machine installation of Win to a BootCamp installation.

  • I'm trying to migrate data from a server to a new one with the file permissions of the files of users and records lost.

    original title: robocopy

    I'm trying to migrate data from a server to a new one with the file permissions of the files of users and records lost. So far, that's what I did, I used \\server1\share \\server2\share/sec /mir robocopy and robocopy \\server1\share \\serve2\share/e/s /copyall. It seams like they copied all files with the permissions of the user for the files, but not files. For example, if a user makes a folder with the files in the folder appear them have permissions appropriate for them but not the root folder or subfolders, they did... How can I fix this and what is the difference between / s /mir and/e/s /copyall?

    Hello

    You can find the Server forums on TechNet support, please create a new post at the following link:

    http://social.technet.Microsoft.com/forums/en/category/WindowsServer/

  • How to migrate data from a source to multiple targets (tables)?

    How to migrate data from a source to multiple targets (tables)? Describe the General steps, please or point me to a tutorial

    Yes, a table in a mapping element can be source and target at the same time (i.e. a target can be reused as a source for the rest of the map on the right side of the table).

    Don't forget to check the order of loading (in the property map), to ensure that the reused as source is loaded before the final table target table.

    I tested it and it works. However, the documentation is not said in the link I gave you above:

    "Each element of data store that has entries but no exits in the logical diagram is considered a target."

    Usually, I tend not to do. I am in favour of a Divide and Conquer approach and try to have my mapping as simple as possible. It is easier to debug and maintain.

  • to retrieve data from xml data type

    Hello...
    I have a doubt in the oracle database... Here's how to retrieve data from xml data type?

    Like this...

    SQL> ed
    Wrote file afiedt.buf
    
      1  with t as (select xmltype('
      2  
    3 4 toMonth5 5 ctTestPan1 6 costType2 7 toYear2012 8 fromMonth12 9 fromYear2011 10 11
    ') as xml from dual) 12 -- 13 -- end of sample XMLDATA, use below query on your own table etc. as required 14 -- 15 select x.* 16 from t 17 ,xmltable('/DETAILS/FIELDS_VALUES/FIELD' 18 passing t.xml 19 columns name varchar2(30) path './NAME' 20 ,val varchar2(10) path './VALUE' 21* ) x SQL> / NAME VAL ------------------------------ ---------- toMonth 5 ctTestPan 1 costType 2 toYear 2012 fromMonth 12 fromYear 2011 6 rows selected.
  • How transform the trailing spaces &amp; AREAS of data from sybase to oracle

    Helllo,

    We are the migration of data from sybase to Oracle using goldengate... Source Sybase with SPACES (single / Multiple) as data to CHAR/VARCHAR that will be migrated to the VARCHAR2 data type in Oracle. I'm having trouble trying to implement under two conditions to transform the data

    1) Remove SPACES during the IPL for CHAR/VARCHAR

    example: Data Source: "TRAILING SPACE.

    Given target expected - remove the spaces of trailinging: "TRAILING SPACE.

    2) If the data with SPACES like a value (single or Multiple) will be loaded as a single SPACE in Oracle.

    example : Source data                                                  :  "          "

    Expected data from target - unique space:

    Map: dbo. Target TEST_TABLE DEV01. Table_test, COLMAP (USEDEFAULTS, CRE_ID = @IF (@STRRTRIM (CRE_ID) = @NULL AND CRE_ID <>@NULL, ' ', @STRRTRIM (CRE_ID)));

    I tried above mapping in the settings file, but it returns error like below, guidance on the highest implementation requirement will be useful.

    ... RIM (CRE_ID) = @NULL AND CRE_ID...

    ^

    Error in the COLMAP clause. Invalid function or argument.

    Under column mapping is worked :-)

    Map: dbo. Target TEST_TABLE DEV01. TABLE_TEST, COLMAP (USEDEFAULTS, CRE_ID = @IF (@STRLEN (@STRTRIM (CRE_ID)) = 0, ' ', @STRRTRIM (CRE_ID)));

  • Loading data from SQL to Essbase table

    Hello

    I'm loading data from SQL to Essbase table by using a rules file. Number of rows in the source table is 7 million. I use the SUNOPSIS MEMORY ENGINE as area transit, LKM SQL for SQL and SQL IKM for Hyperion Essbase (DATA).

    Question:

    1 can I not use any other LKM as MSSQL for MSSQL (PCBS) to load data to the staging instead of LKM SQL for SQL? What I have to change the transit area then? Loading data using LKM SQL for SQL seems quite slow.

    2 it is mandatory to use LKM SQL for SQL, can someone please tell me what I can change to make this quick support parameters?

    3. is it compulsory to use the SUNOPSIS MEMORY engine loading data from SQL server to Essbase?

    Thank you...

    (1) Yes, I highly recommend watching using a KM which uses native as database technology these will usually be more efficient than the generic (like LKM SQL for SQL) KM especially when large volumes of data are involved. Your staging will change depends on where you organize data for example if you are using a SQL server specific KM as - MSSQL for MSSQL (PCBS) - you must have a lay-by available on a MSSQL database and have access to the utility of PCBS.

    (2) it is not mandatory to use this KM you can use a KMs supported by your database technology

    (3) it is absolutely not obligatory to use the SUNOPSIS MEMORY engine. This should only be used when you have relatively small amounts of data, as well as all the processes in memory, or in the case where you have no other relational technology to perform the staging on. However, in your case to use wherever you are processesing these large volumes of data you should be staged on a physical such as SQL Server or Oracle database if they are available.

  • How to select data from a remote database table?

    Hi friends,

    I think I've seen before a sqlplus program that can select data from a remote database table?

    Witnessed: IP, SID, PORT

    The following is correct?

    (I am connected to a local database)
    SELECT COUNT (*) IN THE EMP@IP:SID/PORT;


    Thank you very much


    Ms. K

    Salvation;

    I think, that you can create dblink wihtout any problem yet, it's a PROD. After your selection, you can drop dblink

    Respect of
    HELIOS

  • Series read returns the string with excess-need information to extract data from the middle of the string

    I read data from a STI flow meter using the base series writing and reading which used the VISA.  The read string begins with 'OK' or an error code, then a carriage return, then the data follows streaming rate temp pressure flow rate comma comma comma comma Temp... and so on. The string ends with a CR LF.  I need to pull the flow, temperature and pressure data out of the string and write it to a file.  I have difficulties to find a function that will retrieve the data for the string.  Any suggestions?  Thank you.

    Try the subset of string in the palette of the chain.

    Or match the model if you want a more direct control.

    Also a good way is the string analysis, but you must be willing to read oexactly, what happens or an error, pass the entrance.

  • Best way to migrate data from a store of data to a ROW

    Hi all

    I have a maybe simple question.

    I have some SQL clusters to customers that are not configured by the best practices of VMware.

    They are running ESX 4.0 with vCenter 5.0 u2 u2

    Some of them are running two nodes on the same ESX, some of them have mixtures of RDM and data warehouses and LUNS are connected by mixtures of policies of multiple paths.

    I can make changes to the MPP and the separation of the knots without problem, but I was wondering if anyone has recommendations for the data transfer of any store of data that exists in a ROW?

    Obviously if it is possible I would disconnect the data store, add as a RDM again but is it ok to do?

    Are there catches hidden here?

    If this possible isn´t would I need to create a new drive as a vMotion RDM and the storage of the data between the 2?

    I Don t need to migrate data for the operating system, the data on disks, so I can use storage vMotion for this or it would be better to run VMware converter?

    Someone at - it advice or recommendations?

    Thanks in advance

    Mark

    Obviously if it is possible I would disconnect the data store, add as a RDM again but is it ok to do?

    Are there catches hidden here?

    If this possible isn´t would I need to create a new drive as a vMotion RDM and the storage of the data between the 2?

    I Don t need to migrate data for the operating system, the data on disks, so I can use storage vMotion for this or it would be better to run VMware converter?

    Someone at - it advice or recommendations?

    Thanks in advance

    Mark

    You can't add the data store to a server asa RDM because the data store is in VMFS format.

    you could use vmware converter or restore backups to place the data on the rdm.

  • Extract data from xml file item

    I inserted all data from an xml file into an xml table in the database (after creating the directory and getclobdocument function)
    with

    INSERT INTO TEST_XML
    SELECT (XMLTYPE (getCLOBDocument ('MXMLF.xml'))) FROM DUAL;

    Now how to extract the individual item in the relational table my data in the xml table is something like the following.

    rowset <>
    < TransmissionHeader >
    < TransmissionDateTime > 2008 - 12 - 04T 09: 30:47 - 05:00 < / TransmissionDateTime >
    IATA:ISXMLInvoiceV3.1 < version > < / Version >
    < IssuingOrganizationID > 111 < / IssuingOrganizationID >
    < BillingCategory > various < / BillingCategory >
    < / TransmissionHeader >
    < invoice >
    < InvoiceHeader >
    < InvoiceNumber > 182792000 < / InvoiceNumber >
    < invoiceDate > 2007 - 12 - 19 < / InvoiceDate >
    Bill < InvoiceType > < / InvoiceType >
    < LocationCode > EWR < / LocationCode >
    Engineering of < ChargeCategory > < / ChargeCategory >
    < SellerOrganization >
    < > 111 OrganizationID < / OrganizationID >
    < OrganizationDesignator > ZZ < / OrganizationDesignator >
    Zed airlines < Nomorganisation1 > < / Nomorganisation1 >
    < TaxRegistrationID > 111ABC111 < / TaxRegistrationID >
    < CompanyRegistrationID > ABC111ABC < / CompanyRegistrationID >
    Patrick < ContactName > < / ContactName >
    < address >
    < > 111, Zed AddressLine1 headquarters < / AddressLine1 >
    Montreal < CityName > < / Nom_ville >
    < CountryCode > CA < / CountryCode >
    Canada < CountryName > < / CountryName >
    < code postal > 110011 < / code >
    < / address >
    < / SellerOrganization >
    < BuyerOrganization >
    < > 222 OrganizationID < / OrganizationID >
    < OrganizationDesignator > GG < / OrganizationDesignator >
    < Nomorganisation1 > Globe Airlines < / Nomorganisation1 >
    < TaxRegistrationID > GB22200222 < / TaxRegistrationID >
    < CompanyRegistrationID > Go 222 222 < / CompanyRegistrationID >
    George < ContactName > < / ContactName >
    < address >
    < AddressLine1 > 222, Globe headquarters < / AddressLine1 >
    London < CityName > < / Nom_ville >
    < CountryCode > GB < / CountryCode >
    England < CountryName > < / CountryName >
    < code postal > 220022 < / code >
    < / address >
    < / BuyerOrganization >
    < ConditionsPaiement >
    < CurrencyCode > $ < / CurrencyCode >
    < SettlementMonthPeriod > 071203 < / SettlementMonthPeriod >
    < SettlementMethod > I < / SettlementMethod >
    < / ConditionsPaiement >
    < ISDetails >
    < DigitalSignatureFlag > N < / DigitalSignatureFlag >
    < / ISDetails >
    < setting >
    < AttachmentIndicatorOriginal > Y < / AttachmentIndicatorOriginal >
    < / fixing >
    < / InvoiceHeader >
    < LineItem >
    < LineItemNumber > 1 < / LineItemNumber >
    < ChargeCode > MRO repairs and review < / ChargeCode >
    < description > package for unique maintenance work. Water VAVLE drain compl. P/N 9350022 < / Description >
    < EndDate > 2007 - 12 - 10 < / EndDate >
    < UOMCode quantity = "EA" > 1.0000 < / quantity >
    < UnitPrice SF = "1" > 300,0000 < / UnitPrice >
    < ChargeAmount > 300,00 < / ChargeAmount >
    < TotalNetAmount > 300,00 < / TotalNetAmount >
    < / LineItem >
    < LineItem >
    < LineItemNumber > 2 < / LineItemNumber >
    < ChargeCode > MRO repairs and review < / ChargeCode >
    < description > material consumption for the single interview. Water VAVLE drain compl. P/N 9350022, S/N FRTR013AW < / Description >
    < EndDate > 2007 - 12 - 10 < / EndDate >
    < UOMCode quantity = "EA" > 1.0000 < / quantity >
    < UnitPrice SF = "1" > 900.0000 < / UnitPrice >
    < ChargeAmount > 900.00 < / ChargeAmount >
    < TotalAddOnChargeAmount > 180.00 < / TotalAddOnChargeAmount >
    < TotalNetAmount > 1080.00 < / TotalNetAmount >
    < / LineItem >
    < LineItemDetail >
    < DetailNumber > 1 < / DetailNumber >
    < LineItemNumber > 1 < / LineItemNumber >
    < description > package for unique maintenance work. Water VAVLE drain compl. P/N 9350022 < / Description >
    < EndDate > 2007 - 12 - 10 < / EndDate >
    < UOMCode quantity = "EA" > 1.0000 < / quantity >
    < UnitPrice > 300,0000 < / UnitPrice >
    < ChargeAmount > 300,00 < / ChargeAmount >
    < TotalNetAmount > 300,00 < / TotalNetAmount >
    < AircraftDetails >
    < AircraftRegistrationNo > DAIGS < / AircraftRegistrationNo >
    < PartNo > 9350022 < / PartNo >
    < / AircraftDetails >
    < / LineItemDetail >
    < LineItemDetail >
    < DetailNumber > 1 < / DetailNumber >
    < LineItemNumber > 2 < / LineItemNumber >
    < description > material consumption diaphragm < / Description >
    < EndDate > 2007 - 12 - 10 < / EndDate >
    < UOMCode quantity = "EA" > 1.0000 < / quantity >
    < UnitPrice > 200.0000 < / UnitPrice >
    < ChargeAmount > 200.00 < / ChargeAmount >
    < AddOnCharges >
    Handling of < AddOnChargeName > < / AddOnChargeName >
    < AddOnChargePercentage > 20.00 < / AddOnChargePercentage >
    < AddOnChargeableAmount > 200.00 < / AddOnChargeableAmount >
    < AddOnChargeAmount > 40.00 < / AddOnChargeAmount >
    < / AddOnCharges >
    < TotalNetAmount > 240.00 < / TotalNetAmount >
    < AircraftDetails >
    < AircraftRegistrationNo > DAIGS < / AircraftRegistrationNo >
    < PartNo > 9350584 < / PartNo >
    < / AircraftDetails >
    < / LineItemDetail >
    < LineItemDetail >
    < DetailNumber > 2 < / DetailNumber >
    < LineItemNumber > 2 < / LineItemNumber >
    < description > material consumption coverage < / Description >
    < EndDate > 2007 - 12 - 10 < / EndDate >
    < UOMCode quantity = "EA" > 1.0000 < / quantity >
    < UnitPrice > 177.5000 < / UnitPrice >
    < ChargeAmount > 177,50 < / ChargeAmount >
    < AddOnCharges >
    Handling of < AddOnChargeName > < / AddOnChargeName >
    < AddOnChargePercentage > 20.00 < / AddOnChargePercentage >
    < AddOnChargeableAmount > 177,50 < / AddOnChargeableAmount >
    < AddOnChargeAmount > 35.50 < / AddOnChargeAmount >
    < / AddOnCharges >
    < TotalNetAmount > 213,00 < / TotalNetAmount >
    < AircraftDetails >
    < AircraftRegistrationNo > DAIGS < / AircraftRegistrationNo >
    < PartNo > 9350595 < / PartNo >
    < / AircraftDetails >
    < / LineItemDetail >
    < LineItemDetail >
    < DetailNumber > 3 < / DetailNumber >
    < LineItemNumber > 2 < / LineItemNumber >
    Assembly of material consumption - Base < description > < / Description >
    < EndDate > 2007 - 12 - 10 < / EndDate >
    < UOMCode quantity = "EA" > 1.0000 < / quantity >
    < UnitPrice > 520.0000 < / UnitPrice >
    < ChargeAmount > 520.00 < / ChargeAmount >
    < AddOnCharges >
    Handling of < AddOnChargeName > < / AddOnChargeName >
    < AddOnChargePercentage > 20.00 < / AddOnChargePercentage >
    < AddOnChargeableAmount > 520.00 < / AddOnChargeableAmount >
    < AddOnChargeAmount > 104.00 < / AddOnChargeAmount >
    < / AddOnCharges >
    < TotalNetAmount > 624,00 < / TotalNetAmount >
    < AircraftDetails >
    < AircraftRegistrationNo > DAIGS < / AircraftRegistrationNo >
    < PartNo > 9350598 < / PartNo >
    < / AircraftDetails >
    < / LineItemDetail >
    < LineItemDetail >
    < DetailNumber > 4 < / DetailNumber >
    < LineItemNumber > 2 < / LineItemNumber >
    Packaging material consumption < description > < / Description >
    < EndDate > 2007 - 12 - 10 < / EndDate >
    < UOMCode quantity = "EA" > 1.0000 < / quantity >
    < UnitPrice > 0.0800 < / UnitPrice >
    < ChargeAmount > 0.08 < / ChargeAmount >
    < AddOnCharges >
    Handling of < AddOnChargeName > < / AddOnChargeName >
    < AddOnChargePercentage > 20.00 < / AddOnChargePercentage >
    < AddOnChargeableAmount > 0.08 < / AddOnChargeableAmount >
    < AddOnChargeAmount > 0.02 < / AddOnChargeAmount >
    < / AddOnCharges >
    < TotalNetAmount > 0.10 < / TotalNetAmount >
    < AircraftDetails >
    < AircraftRegistrationNo > DAIGS < / AircraftRegistrationNo >
    < PartNo > AS3209-009 < / PartNo >
    < / AircraftDetails >
    < / LineItemDetail >

    How now?

    Please a little help

    I tried to instead of but of no use

    The new element in the root is 'InvoiceTransmission', so replace 'Lines' with it.
    In addition, there is now a default namespace, you must declare it as well:

    SELECT x1.InvoiceNumber
         , x1.InvoiceDate
         , x1.InvoiceType
         , x1.LocationCode
         , x2.*
         , x3.*
    FROM test_xml t
       , XMLTable(
           XMLNamespaces(default 'http://www.IATA.com/IATAAviationInvoiceStandard')
         , '/InvoiceTransmission/Invoice'
           passing t.object_value
           columns InvoiceNumber   number       path 'InvoiceHeader/InvoiceNumber'
                 , InvoiceDate     date         path 'InvoiceHeader/InvoiceDate'
                 , InvoiceType     varchar2(30) path 'InvoiceHeader/InvoiceType'
                 , LocationCode    varchar2(3)  path 'InvoiceHeader/LocationCode'
                 , LineItems       xmltype      path 'LineItem'
                 , LineItemDetails xmltype      path 'LineItemDetail'
         ) x1
       , XMLTable(
           XMLNamespaces(default 'http://www.IATA.com/IATAAviationInvoiceStandard')
         , '/LineItem'
           passing x1.LineItems
           columns LineItemNumber         number        path 'LineItemNumber'
                 , ChargeCode             varchar2(80)  path 'ChargeCode'
                 , Description            varchar2(200) path 'Description'
                 , EndDate                date          path 'EndDate'
                 , Quantity               number(8,4)   path 'Quantity'
                 , Quantity_UOM           varchar2(3)   path 'Quantity/@UOMCode'
                 , UnitPrice              number(8,4)   path 'UnitPrice'
                 , UnitPrice_SF           varchar2(3)   path 'UnitPrice/@SF'
                 , ChargeAmount           number(6,2)   path 'ChargeAmount'
                 , TotalAddOnChargeAmount number(6,2)   path 'TotalAddOnChargeAmount'
                 , TotalNetAmount         number(6,2)   path 'TotalNetAmount'
         ) x2
       , XMLTable(
           XMLNamespaces(default 'http://www.IATA.com/IATAAviationInvoiceStandard')
         , '$d/LineItemDetail[LineItemNumber=$lin]'
           passing x1.LineItemDetails as "d"
                 , x2.LineItemNumber as "lin"
           columns AircraftRegistrationNo varchar2(30) path 'AircraftDetails/AircraftRegistrationNo'
                 , PartNo                 varchar2(30) path 'AircraftDetails/PartNo'
         ) x3
    ;
    
  • Extract data from xml zipped files.

    Hello
    I have a table with a blob field and because of space constraints, I save my huge xml file in the format compressed in this blob field.
    Is it possible to extract data from the blob field xml?

    Thank you

    Vincent pek

    Yes.

    Have a look here: http://technology.amis.nl/blog/8090/parsing-a-microsoft-word-docx-and-unzip-zipfiles-with-plsql (be aware, "docx" is also a zip file)

Maybe you are looking for

  • Satellite Pro 4200 series and RAM

    They told me that if you install windows xp, it is possible to extend the RAM from 2.56 to 3.84 MB. It would be possible by putting a 256 MB instead of the 128 MB card in the slot.

  • HP Pavilion Notebook 15-p020ca: HP Pavilion p020ca 15, will not capture 5.0 GHz signals

    So my laptop to get signal from my d-link router which was 5.0 GHz, but now it doesn't. It has only been a few days he did this, and I've updated all the drivers. Again is not to choose this signal, what do I do? I really need to use 5.0 GHz as there

  • How to use the string as a terminal window control

    Hi all I am setting up a terminal window in my VI and to do this I have a control of the chain and an indicator of the chain. I want the user to be able to write a command in the terminal and when hitting enter into the control must update, but not b

  • On XP sp3, remove Outlook Express 6,

    On XP sp3, remove Outlook Express 6, he can't find in Add/Remove. Even searched the hidden folders. Can't, also tried in programs, accessories, etc. How can it be deleted so that we can try a re - install. ? Currently, OE will not display the text of

  • Windows 7 will install the necessary drivers on my computer hard disc?

    I want to reformat my hard drive and install windows 7 home edition premoum, he located and install the necessary drivers, so that my computer works normally, the drivers of motherboard etc.