XML Input Stage

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
ravij
Premium Member
Premium Member
Posts: 170
Joined: Mon Oct 10, 2005 7:04 am
Location: India

XML Input Stage

Post by ravij »

Hi,
I am using XML stage first time. Please correct me If am wrong.

We are loading xml data which is existing in Oracle table in a single col as LOB, and using XM Input Stage to pick the data from table and load XML data into Oracle table. I am trying to import col definition from XSD file(we have xsd file for our xml file)in Output page of XML Input stage using 'XML Table Definition'. When import the col definition, its giving error as
Type 'http://www.w3.org/2001/XMLSchema:DetailsType' is not declared. An error occured at file:///D:abcd.xsd,(219,6).
Please provide the solution how to approach.
Thanks in advance.
Ravi
eostic
Premium Member
Premium Member
Posts: 3838
Joined: Mon Oct 17, 2005 9:34 am

Post by eostic »

It's possible that the xsd is not complete or is invalid...or it could be that it contains one of several constructs that the pack is unable to read.....

As an alternative, get a complete document sample for it.....and import that...the importer can import xml documents as easily as xsd's... just be sure to generate an xml document that has each possible element populated.

Search thru this forum..there are LOTs of valuable entries on xml that you will want to be reviewing, including the "best practices" document for xml that you will find at Kim Duke's site.

Ernie
Ernie Ostic

blogit!
<a href="https://dsrealtime.wordpress.com/2015/0 ... ere/">Open IGC is Here!</a>
ravij
Premium Member
Premium Member
Posts: 170
Joined: Mon Oct 10, 2005 7:04 am
Location: India

Post by ravij »

Thanks for your reply Eostic.

I tried with one sample xml file, i was able to import through Load->XML Definition, but the metadata is not getting saved into repository. How can I save the metada and load the same into my Columns Tab in Output page.

appreciate your help.
Thanks in advance.
Ravi
eostic
Premium Member
Premium Member
Posts: 3838
Joined: Mon Oct 17, 2005 9:34 am

Post by eostic »

You should be using the "Import....Table Definitions....XML Definitions" wizard, and then opening your xml document. When you get there, open the entire tree.....

Look carefully thru it. Do NOT pick "autocheck".....instead, review exactly which LOWEST LEVEL elements and attributes that you want to access, and check those (the boxes with a "T" next to them are elements, the ones with the orange-ish icon are attributes) -- they are what become "columns" for retrieval.

Checking parent nodes is for advanced techniques, but will just confuse you if you are getting started.

There is a file...save in that import dialog.....it will create a table def for you for import onto the input link side of the xml Input Stage.

Ernie
Ernie Ostic

blogit!
<a href="https://dsrealtime.wordpress.com/2015/0 ... ere/">Open IGC is Here!</a>
Post Reply