Hi,
I am usnig external source to read xml files and XMl input stage to parse the xml message.
My schema is having a target name space because of which in my XMLInput Stage --> Output --> Columns --> description tab it is shown as /defns:..
I am able to compile the job and at the time of execution it is giving error like "The prefix defns is not declared" and Error occured in call to ORPHCallActivePluginInitialize().
Can any one help how to deal with this?
-Thanks,
Raj.
Using XML Input Stage with External Source Stage
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 19
- Joined: Fri May 14, 2010 3:54 pm
Using XML Input Stage with External Source Stage
Rajesekhar Potteti
How did you generate the metadata / XPath Expressions you are using? From an xsd for your source file? Can you post some examples of them, please? Also, did you load your namespace definition? From the docs...
If you used the XML Meta Data Importer to create table definitions, select the Include namespace declaration box and click the Load button to extract namespace declarations from a specific table definition.
-craig
"You can never have too many knives" -- Logan Nine Fingers
"You can never have too many knives" -- Logan Nine Fingers
-
- Participant
- Posts: 19
- Joined: Fri May 14, 2010 3:54 pm
Yes right.. I am using xsd to create metadata. Import --> tableDefinitions --> XML table definitions.
From here I am selecting the file which is there on my local system, checking all the necessary attributes and saving the datadefinitions.
In XML Input Stage --> Output --> Columns Iam loading these data definitions.
When I do this in description column it is given as /defns:.. which I believe is improper.
Here is the snippet of schema iam usnig..
<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.something.com/1.0/site" elementFormDefault="qualified" version="1.0">
<xs:element name="Message_Name">
<xs:annotation>
<xs:documentation>CDATA Format: :<![CDATA[ABC|DEF|GHI]]></xs:documentation>
</xs:annotation>
</xs:element>
</xs:schema>
From here I am selecting the file which is there on my local system, checking all the necessary attributes and saving the datadefinitions.
In XML Input Stage --> Output --> Columns Iam loading these data definitions.
When I do this in description column it is given as /defns:.. which I believe is improper.
Here is the snippet of schema iam usnig..
<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://www.something.com/1.0/site" elementFormDefault="qualified" version="1.0">
<xs:element name="Message_Name">
<xs:annotation>
<xs:documentation>CDATA Format: :<![CDATA[ABC|DEF|GHI]]></xs:documentation>
</xs:annotation>
</xs:element>
</xs:schema>
Rajesekhar Potteti
-
- Participant
- Posts: 19
- Joined: Fri May 14, 2010 3:54 pm
Hi Craig,
Good Catch, I didnt load namespace definitions. but I manuaaly inserted them on to Stage --> Transformaiton Setting.
Need your help in understanding how to load namespace definitions, some article would help.
I just tried using a proper schema (instead of using flat file structure in document, used actual elements and other properties) and the corresponding xml file and it worked.
I am new to DataStage, but I am having work experience in WMB and WTX. Hope to learn DS quick.
-Thanks for your help.
Good Catch, I didnt load namespace definitions. but I manuaaly inserted them on to Stage --> Transformaiton Setting.
Need your help in understanding how to load namespace definitions, some article would help.
I just tried using a proper schema (instead of using flat file structure in document, used actual elements and other properties) and the corresponding xml file and it worked.
I am new to DataStage, but I am having work experience in WMB and WTX. Hope to learn DS quick.
-Thanks for your help.
Rajesekhar Potteti
Hi
after loading the table definations
need to load the columns it will be tree like structure.....
it is the error i think so....
this should be done in xml table data definations
Thanks
after loading the table definations
need to load the columns it will be tree like structure.....
it is the error i think so....
this should be done in xml table data definations
Thanks
chulett wrote:How did you generate the metadata / XPath Expressions you are using? From an xsd for your source file? Can you post some examples of them, please? Also, did you load your namespace definition? From the docs...
If you used the XML Meta Data Importer to create table definitions, select the Include namespace declaration box and click the Load button to extract namespace declarations from a specific table definition.
Ragu
Default namespaces can be a pain to work with. As Craig suggests, put a snippet of xml here so we can see..just need the first couple of elements and attributes near the top along with the all-important header..... share your xpath also (the Description property of your xmlInput Stage's output link).
Ernie
Ernie
Ernie Ostic
blogit!
<a href="https://dsrealtime.wordpress.com/2015/0 ... ere/">Open IGC is Here!</a>
blogit!
<a href="https://dsrealtime.wordpress.com/2015/0 ... ere/">Open IGC is Here!</a>