user6276653
user6276653

Reputation: 140

Import XML file in Oracle XML DB Repository

I am new to XML databases. I have the following XML file (employees.xml) :-

<?xml version="1.0"?>
<emps>
    <emp empno="1" deptno="10" ename="John"  salary="21000"/>
    <emp empno="2" deptno="10" ename="Jack" salary="310000"/>
    <emp empno="3" deptno="20" ename="Jill" salary="100001"/>
</emps>

I want to load it in my Oracle XML DB Repository (under "public" folder) so that I can access it later using XQJ. Oracle is locally installed in my machine. Any clues how to import the XML file ?

Upvotes: 0

Views: 212

Answers (1)

Graham Nicol
Graham Nicol

Reputation: 173

The various technologies for loading XML Data into the tables are documented here.

Basically use the lobfile function in SQLLoader to get the file as a whole and insert it into your XML column.

Upvotes: 0

Related Questions