Loading the XML in Oracle XML Table/OWB

Hi gurus,

Need help to load the XML file into oracle XML table /OWB.

Here is an example of XML file

< GEBIZ_PURCHASE_ORDER xmlns = "http://ordabc.xmlbeans.order.importexport.de" >
< HEADER >
external < ORDER_CODE > < / ORDER_CODE >
< EXTERNAL_SYSTEM_CODE > E < / EXTERNAL_SYSTEM_CODE >
< AMENDMENT_NUMBER > 1 < / AMENDMENT_NUMBER >
< VARIATION_NUMBER > 1 < / VARIATION_NUMBER >
document in < DESCRIPTION > < / DESCRIPTION >
< FINANCIAL_SYSTEM >
PR < SUB_BUSINESS_UNIT > < / SUB_BUSINESS_UNIT >
< NFS >
< COST_CENTER_GROUP > 21 < / COST_CENTER_GROUP >
< BUYER_CODE > 121 < / BUYER_CODE >
< FINANCIAL_SYSTEM_ORDER_CODE > 23 < / FINANCIAL_SYSTEM_ORDER_CODE >
< USER_NRIC > 8 < / USER_NRIC >
< / NFS >
< SAP >
< PURCHASING_GROUP > 3 < / PURCHASING_GROUP >
< / SAP >
< / FINANCIAL_SYSTEM >
< STATUS > ELEMENT < / STATUS >
< / Header >
ELEMENTS <>
< ITEM >
< LINE_NUMBER > 1 < / LINE_NUMBER >
the COSTS OF HANDLING < DESCRIPTION > < / DESCRIPTION >
< UNIT_OF_MEASURE > M < / UNIT_OF_MEASURE >
< QUANTITY > 12 < / QUANTITY >
SERVICES < LINE_TYPE > < / LINE_TYPE >
< UNIT_PRICE > 12 < / UNIT_PRICE >
< PRICE_UNIT > 12 < / PRICE_UNIT >
< > 12 TOTAL_AMOUNT < / TOTAL_AMOUNT >
< STATUS > < / STATUS >
< / POINT >
< ITEM >
< LINE_NUMBER > 2 < / LINE_NUMBER >
COSTS OF HANDLING CARGO < DESCRIPTION > < / DESCRIPTION >
< UNIT_OF_MEASURE > M < / UNIT_OF_MEASURE >
< QUANTITY > 13 < / QUANTITY >
SERVICES < LINE_TYPE > < / LINE_TYPE >
< UNIT_PRICE > 14 < / UNIT_PRICE >
< PRICE_UNIT > 14 < / PRICE_UNIT >
< > 1200 TOTAL_AMOUNT < / TOTAL_AMOUNT >
< STATUS > STATUSDELIVERED < / STATUS >
< / POINT >
< / OBJECT >
< / GEBIZ_PURCHASE_ORDER >

I created the table and the procedure below

create the table xxpo_estimate_details
(ORDER_CODE, varchar2 (100),)
EXTERNAL_SYSTEM_CODE varchar2 (100),
AMENDMENT_NUMBER varchar2 (100),
VARIATION_NUMBER varchar2 (100),
DESCRIPTION varchar2 (100),
SUB_BUSINESS_UNIT varchar2 (100),
COST_CENTER_GROUP varchar2 (100),
BUYER_CODE varchar2 (100),
FINANCIAL_SYSTEM_ORDER_CODE varchar2 (100),
USER_NRIC varchar2 (100),
PURCHASING_GROUP varchar2 (100),
FS_STATUS varchar2 (100),
PR_LINE_NUMBER varchar2 (100),
PR_DESCRIPTION varchar2 (100),
UNIT_OF_MEASURE varchar2 (100),
PR_QUANTITY varchar2 (100),
LINE_TYPE varchar2 (100),
Unit_price varchar2 (100),
PRICE_UNIT varchar2 (100),
TOTAL_AMOUNT varchar2 (100),
PR_STATUS varchar2 (100));


declare
acct_doc xmltype: = xmltype (bfilename('FLAT_FILES','PO_DETAILS_COPY.xml'), nls_charset_id ('AL32UTF8'));
BEGIN
insert into xxpo_estimate_details
(ORDER_CODE,
EXTERNAL_SYSTEM_CODE,
AMENDMENT_NUMBER,
VARIATION_NUMBER,
DESCRIPTION,
SUB_BUSINESS_UNIT,
COST_CENTER_GROUP,
BUYER_CODE,
FINANCIAL_SYSTEM_ORDER_CODE,
USER_NRIC,
PURCHASING_GROUP,
FS_STATUS,
PR_LINE_NUMBER,
PR_DESCRIPTION,
UNIT_OF_MEASURE,
PR_QUANTITY,
LINE_TYPE,
UNIT_PRICE,
PRICE_UNIT,
TOTAL_AMOUNT,
PR_STATUS
)
SELECT X 1. ORDER_CODE,
X 1. EXTERNAL_SYSTEM_CODE,
X 1. AMENDMENT_NUMBER,
X 1. VARIATION_NUMBER,
X 1. DESCRIPTION,
X 1. SUB_BUSINESS_UNIT,
X 1. COST_CENTER_GROUP,
X 1. BUYER_CODE,
X 1. FINANCIAL_SYSTEM_ORDER_CODE,
X 1. USER_NRIC,
X 1. PURCHASING_GROUP,
X 1. STATUS,
X 2. LINE_NUMBER,
X 2. DESCRIPTION,
X 2. UNIT_OF_MEASURE,
X 2. QUANTITY,
X 2. LINE_TYPE,
X 2. UNIT_PRICE,
X 2. PRICE_UNIT,
X 2. TOTAL_AMOUNT,
X 2. STATUS
FROM XMLTABLE)
' / GEBIZ_PURCHASE_ORDER/HEADER.
passage acct_doc
header_no of columns for the ordinalite,
Path of varchar2 (100) ORDER_CODE "ORDER_CODE"
Path of varchar2 (100) EXTERNAL_SYSTEM_CODE "EXTERNAL_SYSTEM_CODE"
Path of AMENDMENT_NUMBER VARCHAR2 (100) "AMENDMENT_NUMBER."
PATH OF VARCHAR2 (10) VARIATION_NUMBER "VARIATION_NUMBER"
DESCRIPTION VARCHAR2 (100) PATH "DESCRIPTION."
PATH OF VARCHAR2 (100) SUB_BUSINESS_UNIT "FINANCIAL_SYSTEM/SUB_BUSINESS_UNIT,"
PATH OF VARCHAR2 (10) COST_CENTER_GROUP "FINANCIAL_SYSTEM/NFS/COST_CENTER_GROUP,"
PATH OF VARCHAR2 (50) BUYER_CODE "FINANCIAL_SYSTEM/NFS/BUYER_CODE,"
PATH OF VARCHAR2 (50) FINANCIAL_SYSTEM_ORDER_CODE "FINANCIAL_SYSTEM/NFS/FINANCIAL_SYSTEM_ORDER_CODE,"
PATH OF VARCHAR2 (50) USER_NRIC "FINANCIAL_SYSTEM/NFS/USER_NRIC,"
PATH OF VARCHAR2 (50) PURCHASING_GROUP "FINANCIAL_SYSTEM/SAP/PURCHASING_GROUP,"
PATH VARCHAR2 (50) STATUS 'STATUS '.
) X 1,
XMLTable)
' / GEBIZ_PURCHASE_ORDER/ITEMS/ITEM ".
passage acct_doc
columns for the ordinalite header_no
path of columns LINE_NUMBER varchar2 (10) "LINE_NUMBER.
Path varchar2 (100) DESCRIPTION "DESCRIPTION."
PATH OF VARCHAR2 (100) UNIT_OF_MEASURE "UNIT_OF_MEASURE"
PATH VARCHAR2 (10) OF "QUANTITY."
PATH OF VARCHAR2 (100) LINE_TYPE "LINE_TYPE"
PATH OF VARCHAR2 (10) UNIT_PRICE "UNIT_PRICE."
PATH OF VARCHAR2 (10) PRICE_UNIT "PRICE_UNIT"
PATH OF VARCHAR2 (10) TOTAL_AMOUNT 'TOTAL_AMOUNT ';
PATH VARCHAR2 (120) STATUS 'STATUS '.
) X 2;
-EXCEPTION
-WHILE OTHERS THEN
-DBMS_OUTPUT. PUT_LINE (' ERROR ' |) SQLERRM);
END;

When I run the above procedure, it runs successfully but the records charge not in the table.

When I remove the attribute xmlns = "http://ordabc.xmlbeans.order.importexport.de" and start the process, and then load the records.

can you please is it possible in the xml file without change? (deletion of the attribute)

If choose table for loading XML /OWB XML files then what are challeges and challenges we face.

Add two expressions XMLTable XMLNAMESPACES clause:

...

FROM XMLTABLE(
  XMLNamespaces(default 'http://ordabc.xmlbeans.order.importexport.de')
, '/GEBIZ_PURCHASE_ORDER/HEADER'

...

Tags: Oracle Development

Similar Questions

  • Load the XML file into oracle DB using OWB

    Hi friends,

    I'm new XML data.
    I had a requirememnt to load the xml file into an oracle table.
    Can someone procedure to load the data.

    Thanks in advance

    see this

    http://blogs.Oracle.com/warehousebuilder/2007/09/leveraging_xdb.html

  • Load the XML data to the UNIX server directly to Tables of database relational

    Is there a way I can load some data from an XML file in the Oracle Tables, without going through the input file XML in a directory of the Oracle server. My XML file resides on the UNIX application server. And I need to load the data directly into database tables. Without load them into the database directory.


    Also, I'm looking for a solution that would not load my database much and affect other processes running. Can be done using SQL Loader?


    Oracle database version: Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64 bit Production

    Thanks for the companions of answers!

    There I helped to learn a lot of options.

    But the easiest using UNIX server that worked for me was to use an XSLT transformation to convert the XML file to a delimited file. (Load the unix server, save the Oracle resources).

    UNIX 'xsltproc' feature was not a bad option.

    Then use SQL Loader to load into tables.

    Bravo!

    Rahul

  • load the xml file into a database to help table of travel point

    Hello

    Someone help me please with a possible approach. I have an interface for APEX users where users can download a file xml in apex table wwv_flow_files using the element to browse with a button "submit". Now, after loading the xml file in the wwv_flow_files table. I need to read and load the xml data into a table sample_tbl. I'm using the version of Oracle APEX 4.0 and Oracle 10 g R2 database. Here is an example of XML file to load. Please help me possible suggestions.

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

    < dataroot generated =... >

    < MySample >

    < KeyId > 1234 < / KeyId >

    eddskc < KeyName > < / KeyName >

    < scheduleDate > 2013-06-16T 00: 00:00 < / ScheduleDate >

    < StartTime > 2013-06-16T 08: 00:00 < / StartTime >

    < EndTime > 2013-06-16T 08:30:00 < / EndTime >

    < / MySample >

    < MySample >

    < KeyId > 5678 < / KeyId >

    jppdf < KeyName > < / KeyName >

    < scheduleDate > 2013-05-19T 00: 00:00 < / ScheduleDate >

    < StartTime > 2013-05-19T 08: 00:00 < / StartTime >

    < EndTime > 2013-05-19T 08:30:00 < / EndTime >

    < / MySample >

    < / dataroot >

    Thanks in advance.

    Thank you

    Orton

    orton607 wrote:

    My sample_tbl has a start_time field and its data type DATE.

    Good.  Be sure to always store dates as the DATE.

    The application (in this case, APEX) needs to format the date date type in the appropriate human-readable format.

    The problem with the incoming data is the 't'.  You will need to convert a space using REPLACE() in the framework so that your SELECT statement

    From there on, conversion to the DATE data type is simply

    to_date( replace( start_time_str, 'T', ' '), 'YYYY-MM-DD HH24:MI:SS') as start_time
    

    And, just in case where, the conversion of DATE for the desired format:

    to_char( start_time, 'MM/DD/YYYY HH12:MI:SS AM')
    

    Although, I'm 'hours' as being left-padded with zeros... Am I looking for how / if you can get rid of the zero prefix (0).

  • Can't view the data after loading the XML into RTF model

    Hi friends

    I am unable to view data in PDF after loading the XML into RTF model
    After I load the XMl file to my model
    The complement of the tab, I'm trying to get a glimpse of the output as pdf/xml etc, but he throws and error
    Window does not
    'C:\DOCUME~1\SYSNAME~\LOCALS~\APPLIC~1\Oracle\BIPUBL~1\TEMPLA~\tmp\3513518782149421out.pdf214921out.pdf '. Make sure you typed the name correctly and then try again. To search for a file, click the Start button and click Search

    I gave the name correctly only, but don't know y it displays error I have to reinstall the Office of Oracle BI Publisher once more please advice me what needs to be done to solve my problem of my PC

    Thank you
    Thiliban

    It seems that the problem is with the working directory of the BIP Office.

    If you have administrator access to the computer, please do the following:
    1 Windows-> Run-> regedit
    2. find the value of the next entry
    Publisher\Template HKEY_CURRENT_USER\Software\Oracle\XML for Word\TB_WORK_DIR generator
    3. change your path C:\DOCUME~1\SYSNAME~\LOCALS~\APPLIC~1\ORACLE\BIPUBL~1\TEMPLA~\tmp

    See you soon,.
    ND
    Use the buttons "useful" or "correct" to award points to the answers / mark the thread as answered, if your question is answered.

  • Load the xml into the mc symbols

    I am new to the integration of xml in my flash. I have used the components that make the link between for me, but have never tried to do the code myself. My project is a simple slideshow, which has transitions on the timeline that are very important to the project. I created an image holder movie clip symbol that is the same size as my images. I created the slideshow using multiple instances (each with its own instance name slide01, slide02, etc.) of this medium. All I want to do is to load from a xml file .jpg files to fill the files with the licensee prior to execution. I got the code works for the first image, but none of the others will fill. I am trying to load the xml data into a table, and then draw the table to fill the mc symbols. I modified the code I found in a tutorial. Help, please!

    You must slide01 movieclips,... slide10 to exist when this code runs.

    to see your images load those jpgs must be in the same directory as your html incorporation (or swf so you test in the flash test environment) and your movieclips slides must be visible (and does not cover the other).

  • load the XML file field Companion without cross-domain policy file

    Hello.

    Assuming that there are two areas companions on the same server: /public_html/domain1.com and /public_html/domain2.com

    I'm trying to load the XML from domain2.com in domain1.com without using a cross-domain policy file (since it does not work with xml files in my case).

    So the idea is to use a php file to load XML and read it back to Flash.

    I found an interesting scripts that seems to do the job, but unfortunately I can't make it work. In my opinion, there is somewhere with AS3 part problem. Please take a look.

    Here's the AS3/PHP scripts:

    AS3 (.swf in www.domain1.com):

    location of the xml file you want to load, full http address

    var xmlLoc:String = " " http://www.Domain2.com/MyFile.XML ";

    location of the php xml grabber, regarding the .swf

    var phpLoc:String = "loadXML.php";

    var xml;

    var loader: URLLoader = new URLLoader();

    var request: URLRequest = new URLRequest (phpLoc + "? location =" + escape (xmlLoc));

    loader.addEventListener (Event.COMPLETE, onXMLLoaded);

    loader.addEventListener (IOErrorEvent.IO_ERROR, onIOErrorHandler);

    Loader.Load (request);

    function onIOErrorHandler(e:IOErrorEvent):void {}

    trace ("there was an error with the xml file" + e);

    }

    function onXMLLoaded(e:Event):void {}

    trace ("RSS feed has been loaded");

    XML = new XML (loader.data);

    / / string value, because it is passed from php as object

    XML = XML (xml.toString ());

    xml_txt.text = xml;

    }

    PHP (loadXML.php to www.domain1.com):

    <? PHP

    Header ("Content-type: text/xml");

    $location = "";

    {if (isset($_GET["location"]))}

    $location = $_GET ['location'];

    $location = urldecode ($location);

    }

    $xml_string = getData ($location);

    return the url encoded Flash vars

    echo $xml_string;

    Loops of a URL and returns

    function getData ($query) {}

    / / create resource curl

    $ch = function curl_init();

    / / cURL url

    curl_setopt ($ch, CURLOPT_URL, $query);

    Set some required params for the use of CURL

    curl_setopt ($ch, CURLOPT_SSL_VERIFYPEER, false);

    curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);

    Execute the loop works and decode the returned JSON data

    $result = curl_exec;

    return $result;

    / / Close the curl resource to free up system resources

    curl_close ($ch);

    }

    ? >

    I think you might be right about / permissions on the server for php settings. Unfortunately I'm not allowed to adjust.

    So I wrote my own script - this time I used the path instead of the http address of the XML file.  It works fine in my case.

    Here it is:

    XML file on domain2.com:

    SWF on domain1.com:

    var imagesXML:XML;

    var variables: URLVariables = new URLVariables();

    var varURL:URLRequest = new URLRequest ("MyPHPfile.php");

    varURL.method = URLRequestMethod.POST;

    variable = varURL.data;

    var MyLoader:URLLoader = new URLLoader;

    MyLoader.dataFormat = pouvez;

    MyLoader.addEventListener (Event.COMPLETE, XMLDone);

    MyLoader.load (varURL);

    function XMLDone(event:Event):void {}

    var imported_XML:Object = event.target.data.imported_XML;

    imagesXML = new XML (imported_XML);

    MyTextfield_1.text = imagesXML;

    MyTextfield_2.text = imagesXML.image [0] .attribute ("thumbPath");  reference sample to assign "thumbPath' of the first item

    }

    php on domain1.comfile:

    <>

    $xml_file = simplexml_load_file('.. /.. / /galleries/gallery_1/MyXMLfile.xmldomain2.com');  Directory of XML file on the same server

    $imported_XML = $xml_file-> asXML();

    Print "imported_XML =". $imported_XML;

    ?>

    Concerning

    PS: for those who have read the foregoing: the first and the second script works but you need to test which one is best for your situation. The first script will work also between two domains located on different servers. No. cross necessary domain policy file.

  • loading the XML data in password protected URLs

    Using Flash Professional 8...

    I have an application that loads the XML data in remote servers.

    It works fine, except that the company provide me with the data decided to protect their files. It seems they use IIS or .htaccess protection of password for the style.

    I have a valid user name and password, but I do not know how to integrate those when calling the URL to authenticate.

    I think I need to use loadVars objects, but I've not been able to find examples where people use this method for this style of security. I see most of the examples deal with submit a name of user and password on a URL and then receive a response.
    The security of this type does not follow this pattern. The URL is blocked unless a name of user and password is entered in a box even before see pages.

    LoadVars to use for this?

    If Yes, are there an example or something that I can see?

    If this is not the case, how Flash authenticates this style of security?

    This seems like a fairly standard issue, and I am puzzled that I can't yet find other examples. Am I stupid?

    Thank you
    Joe

    Maybe it helps.
    http://www.martijndevisser.com/blog/article/using-HTTP-authorization-headers

  • Cannot find or load the class main oracle.spatial.util.SampleShapefileToJGeomFeature?

    Hello

    Am getting error below when ESRI shapefile running in the oracle database table.,.

    C:\ > java - cp G:\app\product\11.2.0\dbhome_1\jdbc\lib\ojdbc14.jar; G:\app\product\

    11.2.0\dbhome_1\md\jlib\sdoutl-1.0.jar;\g:\app\product\11.2.0\dbhome_1\md\jlib\s

    doapi - 1.0.jar oracle.spatial.util.SampleShapefileToJGeomFeature localhost h Pei

    Forms - sn of 1521 orcl u MDSYS selva d t f F:\saptial\Africa.shp - r 8307 - g ge

    ometry

    Error: Could not find or load the class main oracle.spatial.util.SampleShapefileToJGeomFeature

    Uses the java version

    C:\ > java-version

    Java version "1.7.0_51".

    Java (TM) SE Runtime Environment (build 1.7.0_51 - b13)

    The Client Java VM (build 24.51 - b03, mixed mode, sharing)

    And also tried in MapBuilder sound fine work., but I need to import java utility assistance help me too this.,.

    I tried below in this way and solved problem.,.

    Until I downloaded

    sdoutl - 11.2.0.jar and sdoapi - 11.2.0.jar used to import a shp file...

    C:\>set ORACLE_HOME=G:\app\product\11.2.0\dbhome_1

    C:\Users\SELVA>CD downloads

    C:\Users\SELVA\Downloads>CD statplanet_zambia

    Card C:\Users\SELVA\Downloads\StatPlanet_Zambia>CD

    located in a particular way and my oracle home

    C:\Users\SELVA\Downloads\StatPlanet_Zambia\map>set ORACLE_HOME=G:\app\product\11.2.0\dbhome_1

    C:\Users\SELVA\Downloads\StatPlanet_Zambia\map>java - classpath %ORACLE_HOME%\jdb

    c\lib\ojdbc5.jar;%O RACLE_HOME%\md\jlib\sdoutl-11.2.0.jar;%O RACLE_HOME%\md\jlib\sdoapi-11.2.0.jar oracle.spatial.util.SampleShapefileToJGeomFeature h localhost Pei 1521 - orcl u MDSYS selva t Zambia SF map geometry 8307 d - g - r

    Host: localhost

    Port: 1521

    SID: orcl

    db_username: MDSYS

    DB_PASSWORD: selva

    db_tablename: Zambia

    shapefile_name: map

    SRID: 8307

    db_geometry_column: geometry

    Connection using Oracle10g...

    localhost, 1521, orcl, MDSYS, selva, Zambia, map, null, 8307

    Old table of fall...

    java.sql.SQLException: ORA-00942: table or view does not exist

    Creating a new table...

    9 response (s) converted.

    Fact.

    Thank you

    Selva

  • Load the XML file into Oracle external Table


    I load the data from the XML file into an intermediate table Oracle using external Tables.

    Let's say below, it is my XML file

    < header >
    < A_CNT > 10 < / A_CNT >
    < E_CNT > 10 < / E_CNT >
    < AF_CNT > 10 < / AF_CNT >
    < / header >
    < student >
    <>students-details
    < Student_info >
    < Single_Info >
    < ID > 18 / < ID >
    New York < City > < / City >
    < country > United States < / country >
    < Name_lst >
    < Student_name >
    Samuel < name > < / name >
    Paul < Last_name > < / Last_name >
    < DOB > 19871208 < / DOB >
    Aware of < RecordStatus > < / RecordStatus >
    < / Student_name >
    < Student_name >
    Samuel < name > < / name >
    Paul < Last_name > < / Last_name >
    < DOB > 19871208 < / DOB >

    < TerminationDt > 20050812 < / TerminationDt >
    History of < RecordStatus > < / RecordStatus >
    < / Student_name >
    < / Name_lst >
    < Personal_Info >
    <>men < / Type >
    < 27 > < / Age >
    < / Personal_Info >
    < / Single_Info >
    < / Student_info >

    < student - register >
    class < A >
    < info >
    < detail >
    < ID student > 18 < / student >
    EE < major > < / Major >
    < course-Grades >
    < course > VLSI < / course >
    < degree > 3.0 < / Grade >
    < / course-Grades >
    < course-Grades >
    < course > nanotechnology < / course >
    < degree > 4.0 < / Grade >
    < / course-Grades >
    < / details >
    < detail >
    < ID student > 18 < / student >
    THIS < major > < / Major >
    < / details >
    < / info >
    class < A >
    < Student_Enrol >
    <>students-details
    < student >

    I load this XML data file into a single table using an external Table. Could someone help me please with coding.

    Thank you

    Reva

    Could you please help me how to insert my XML content into that.

    Same as before, try a plain old INSERT:

    insert into xml_pecos

    values)

    XmlType (bfilename ('XML_DIR', "test.xml"), nls_charset_id ('AL32UTF8'))

    );

    But you'll probably hit the same limitation as with the binary XMLType table.

    In this case, you can use FTP to load the file as a resource in the XML DB repository.

    If the XML schema has been registered with the hierarchy enabled then the file will be automatically inserted into the table.

    Could you post the exact statement that you used to save the scheme?

    In the meantime, you can also read this article, I did a few years ago, it covers the XML DB features that may be useful here, including details on how to load the file via FTP:

    https://odieweblog.WordPress.com/2011/11/23/Oracle-XML-DB-a-practical-example/

    And documentation of the course: http://docs.oracle.com/cd/E11882_01/appdev.112/e23094/xdb06stt.htm#ADXDB4672

  • Load the XML file into oracle using sql loader

    Hello

    I'm trying to load an xml file into a table using sqlldr.
    I have a table as follows:
    CREATE TABLE xmlloadtable
    ( id number,
     data_xml XMLType
     )
      XmlType data_xml STORE AS CLOB;
    I have a control file that I know is perfectly false:
    LOAD DATA 
    INFILE '/home/oraread/'
    INTO TABLE xmlloadtable 
    (
    id,
    data_xml 
    )
    I googled for the file control and tried in different ways, but of no use.
    I want to load the entire xml file into the table.
    Can someone help me with the correct control file. Any help is appreciated!

    Try this

    LOAD DATA
    INFILE '/home/oraread/'
    INTO TABLE xmlloadtable
    (id,
     file_name          filler,
     data_xml          lobfile(file_name) terminated by eof
    )
    

    You can add the file as a column name field to your table between the id and xml column and remove the word to fill in the .ldr file if you need to keep the name of the file

  • Problem with the date when you load the XML file into Oracle Database 10g

    Hi all

    I have the interface as shown in the screenshot below. In this document, among other things, I am mapping to an element XML file representing a date to an Oracle table column defined as DATE. The source and target columns are highlighted in the screenshot.

    ! http://img223.imageshack.us/img223/1565/odiscr275.jpg!

    When I run the interface, I get the following error message:

    java.lang.IllegalArgumentException to java.sql.Date.valueOf(Date.java:103)

    I guess that this is the conversion of the date!

    I already tried to replace SRC_TRADES. DEAL_DATE with TO_DATE (SRC_TRADES. DEAL_DATE, ' DD/MM/YYYY') on the implementation tab. This feature was not recognized when I executed the interface, so it did not work! The value of date in the XML file is in the format DD/MM/YYYY .

    I guess that Date SQL Oracle functions do not work in the implementation tab. Could someone let me know:

    1. what the Date Conversion function I could use instead?
    2. where can I find a reference to the methods/functions that I use in the implementation tab (if such a reference exists)?

    See you soon.

    James

    Hello.

    Try changing the area of execution at the staging area. Once you change it, write in the map box just SRC_TRADERS. DEAL_DATE. When you use TO_DATE, the source field typu should be varchar2, no date (as it is in store for your data source)

  • Load the XML complecated file into my DATABASE

    Hello everyone,
    I have an XML file structured like:
    < ROOT_ELEMENT >
    < SUB_ROOT name = "RETOUR_REQ" >
    < tag name = "TAG1" id = "1" >
    < TAG_VALUE > V1 < / TAG_VALUE >
    < / TAG >
    < tag name = "TAG2" id = "2" >
    < TAG_VALUE > V2 < / TAG_VALUE >
    < / TAG >
    < tag name = "TAG3" id = "3" >
    V3 < TAG_VALUE > < / TAG_VALUE >
    < / TAG >
    < / SUB_ROOT >
    < / ROOT_ELEMENT >

    I want to load this XML file in my Oracle 10 g, the structure of the target table is:


    CREATE TABLE IMP_XML_RETOUR)
    FLUX_NAME VARCHAR2 (20), == > tag mapping
    ELMENT_1 VARCHAR2 (20), == >
    ELMENT_2 VARCHAR2 (20), == >
    ELMENT_3 VARCHAR2 (20) == >
    );
    the FLUX_NAME field must be mapped to the path 'ROOT_ELEMENT/SUB_ROOT/@name '.
    the ELMENT_1 field must be mapped to the path 'ROOT_ELEMENT/SUB_ROOT/TAG@name='TAG1'/TAG_VALUE '.
    the ELMENT_2 field must be mapped to the path 'ROOT_ELEMENT/SUB_ROOT/TAG@name='TAG2'/TAG_VALUE '.
    the ELMENT_3 field must be mapped to the path 'ROOT_ELEMENT/SUB_ROOT/TAG@name='TAG3'/TAG_VALUE '.

    There are any PLSQL function that can be used to load my XML file into my table

    Thanks a lot for your answers

    OK, so my example should work for you.

  • Loading the XML file with the missing elements dynamically by ODI

    Hi guys,.

    I have the XML with two nodes Employee and address below. On a daily basis, sometimes the address element might not come from the source xml file, but my interface has columns mapped to the elements of the address, and that is why it may fail because of the source element is not found in the file or data could not get charged because the State 'and' in the sql query that is generated between the employee and address elements.  Is there a way where I can load the data dynamically where I can search in the file only for items (used) present and dynamically loading data only for these items?

    XML file:

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

    < EMP >

    < Empsch >

    < employee >

    < EmployeeID 12345 > < / EmployeeID >

    < original > t < / initials >

    John < name > < / LastName >

    DOE < FirstName > < / name >

    < / employee >

    < address >

    < > 12345 as WorkPhone < / as WorkPhone >

    < WorkAddress > test 234 < / WorkAddress >

    < / address >

    < / Empsch >

    < / EMP >

    Thank you

    Fabien Tambisetty

    I managed to solve it by using left outer joins, and in referring to the structure of the table of the XSD

  • SQLLDR does load the XML file

    Hello

    In 10g r2, I created the ext_acceptance of the table in the schema XDB:

    create the ext_acceptance of xmltype table
    XmlSchema 'external_acceptance.xsd' element 'acceptance ';

    Then I tried to load an XML with a record using this control file:

    DOWNLOAD THE DATA
    + INFILE * +.
    IN THE TABLE TRUNCATE xdb.ext_acceptance
    XMLType (xmldata)
    FIELDS)
    XMLDATA LOBFILE (CONSTANT STD_ACPT_20090414131553_861.dat_996.xml)
    +)+

    The result was no responsible record and no mistake.

    I also tried to create the ext_acceptance table in another schema, but it does not.

    ORA-31000: resource 'external_acceptance.xsd' is not a document schema XDB

    Thanks for your help.

    I had the exact issue with a control file that looked incredibly similar. I added a few pieces to mine and he introduced data 33 times when it was supposed only to arrive at once. But at least I got something!

    DOWNLOAD THE DATA
    INFILE 'ccd.xsd '.
    IN THE SANDBOX TABLE. XHolder
    XMLTYPE (xmldata)
    FIELDS (xmldata LOBFILE (CONSTANT ccd.xsd)
    COMPLETED BY EXPRESSIONS OF FOLKLORE)
    BEGINDATA
    0

Maybe you are looking for