XML Output Stage to a Webservice

A forum for discussing DataStage<sup>®</sup> basics. If you're not sure where your question goes, start here.

Moderators: chulett, rschirm, roy

Post Reply
MrBlack
Participant
Posts: 125
Joined: Wed Aug 08, 2012 8:57 am

XML Output Stage to a Webservice

Post by MrBlack »

I'm looking for some help with the XML Output stage, so far I've just used the stage to write a file to the OS. So my job looks like this so far

Code: Select all

{Database} -> {Transformer} -> {XML Output}
So the input tab of the XML Stage I write my XPath expressions and everything is working great. So the next thing I want to do is instead of writing the file to the file system, I want to take that XML as a BLOB/CLOB/STRING and pass it into a webservice (or a database table, etc...) So my job now looks like

Code: Select all

{Database} -> {Transformer} -> {XML Output} -> {Transformer} -> {Web Service}
My web service just has one column, payload, which I will base64 encode my xml document that I want to upload.

Where I'm stuck is I don't know what the Output Columns on the XML Stage should be? Should my output columns be identical to my input columns? I would think that I would just have one output column which would be my entire finished xml doc, just as if it was going to be written to disk?
MrBlack
Participant
Posts: 125
Joined: Wed Aug 08, 2012 8:57 am

Post by MrBlack »

Solved it!

In the output column of the XML Output stage, define just a single column but in the Description (where you put the XPath when working with XML) just put a single

Code: Select all

/
The datatype I've just left as Unknown and so far that's working. I now have a single sting of xml text that I can do whatever I need to with. I have ran into trouble using a transformer immediately after because I get a

Code: Select all

"ds_input() - row too big for inter stage rowbuffer"
error so I'm just working around that issue right now.
rameshrr3
Premium Member
Premium Member
Posts: 609
Joined: Mon May 10, 2004 3:32 am
Location: BRENTWOOD, TN

Post by rameshrr3 »

Try using LongVarChar datatype, and set teh data element property as XML
Post Reply