Page 1 of 1

Data wrriting to xml file (using xml output stage)

Posted: Mon Oct 25, 2010 12:08 pm
by srinivas Guduru
I need to generate a xml data file

Transformer stage is used before Xml output stage

Out put Xml file is generating correctly except

Starting tag is not ending with closing tag

/accList/accEntry/msgId/text()
.
.
.

/accList/accEntry/relList/relEntry/relSta/text()

<accEntry> tag is not closing with </accEntry> tag


Thanks
Srini

Posted: Mon Oct 25, 2010 12:35 pm
by eostic
Can you provide more details, or cut/paste a resulting small output example? Is it only for one particular row? for any and all of your accEntry instances? Does msgId close correctly? Does accList close correctly? Are the values null? are the values empty?

Ernie

can any one let me know the solution

Posted: Mon Oct 25, 2010 12:35 pm
by srinivas Guduru
can any one let me know the solution for my problem

Thanks

Re: can any one let me know the solution

Posted: Mon Oct 25, 2010 12:53 pm
by srinivas Guduru
The hole record is very big that is why I am not able to send you

/accList is closing correctly at the end of the file with </accList>

<accEntry> is not closing with </accEntry> for each record

and <msgId> is closing properly for every record


Thank you

srini

Re: can any one let me know the solution

Posted: Mon Oct 25, 2010 12:58 pm
by srinivas Guduru
<accList><accEntry><msgId>A1111</msgId>
.
.
.
.
<relEntry>
<seqNum>1</seqNum>
.
.
.
</relEntry>
HERE <accEntry> should be closed with </accEntry>
<relEntry>
<seqNum>1</seqNum>

Thanks

Srini

Thank you

srini[/quote]

Posted: Mon Oct 25, 2010 1:42 pm
by eostic
I have no idea. Never seen that happen directly.....but I wonder about the hierarchy you are creating....

Do you have a "perfect" example version of the whole structure that you would like to create? How do the accEntry elements relate to the relEntry elements? are they one:one ....or can a single accEntry have multiple relEntry elements? (one:many).....

...and if you are saying that accEntry should be closed...where would the "new" one be?.....right after it? If so, would it then have another msgId immediately following?

Ernie

Posted: Mon Oct 25, 2010 1:47 pm
by eostic
One more set of items worth checking...... what element do you have marked as a key? ...and are you using "aggregate"?, and then separately, what happens if you force seqnum to be unique?

Ernie

can you please lookinto this

Posted: Mon Oct 25, 2010 2:14 pm
by srinivas Guduru
[<accList>
<accEntry>
<msgId>A1111</msgId>
<sysId>VGI</sysId>
<actInd>2</actInd>
<accNum>0002-09891824205</accNum>
<accDtls>
<modInd>Securities</modInd>
<custId>CIF5849794</custId>
<accTyp>16</accTyp>
<brchAcc>USA</brchAcc>
<accOpDt>12-jun-2008</accOpDt>
<accSta>01 </accSta>
<accClDt>31-dec-9999</accClDt>
<ownTyp>1</ownTyp></a
ccDtls><relList><relEntry>
<seqNum>1</seqNum>
<relTyp>50</relTyp>
<relCust>1313536716</relCust>
<relAcc>0002-09891824205</relAcc>
<relFNm></relFNm>
<relMNm></relMNm>
<relLNm>-</relLNm>
<relStDt>12-jun-2008</relStDt>
<relEnDt></relEnDt>
<relSta>01 </relSta>
</relEntry><relEntry>
<seqNum>2</seqNum>

like this SeqNum generates [depend on relAcc(0002-09891824205) repetition may be 14 or 12 or 10 times]

example relAcc(0002-09891824205) is repeated 14 times then <seqNum> generates 14 that is <seqNum>14</seqNum>

again relAcc(0003-09891824205) <seqNum> 1 starts <--- before this <seqnum> <accEntry> has to closed with </accEntry> tag

<relCust> is key

Re: can you please lookinto this

Posted: Mon Oct 25, 2010 2:48 pm
by srinivas Guduru
hi this is my sample output
srinivas Guduru wrote:[<accList>
<accEntry>
<msgId>A1111</msgId>
<sysId>VGI</sysId>
<actInd>2</actInd>
<accNum>0002-09891824205</accNum>
<accDtls>
<modInd>Securities</modInd>
<custId>CIF5849794</custId>
<accTyp>16</accTyp>
<brchAcc>USA</brchAcc>
<accOpDt>12-jun-2008</accOpDt>
<accSta>01 </accSta>
<accClDt>31-dec-9999</accClDt>
<ownTyp>1</ownTyp></a
ccDtls><relList><relEntry>
<seqNum>1</seqNum>
<relTyp>50</relTyp>
<relCust>1313536716</relCust>
<relAcc>0002-09891824205</relAcc>
<relFNm></relFNm>
<relMNm></relMNm>
<relLNm>-</relLNm>
<relStDt>12-jun-2008</relStDt>
<relEnDt></relEnDt>
<relSta>01 </relSta>
</relEntry><relEntry>
<seqNum>2</seqNum>

like this SeqNum generates [depend on relAcc (0002-09891824205) repetition seqnum may be 14 or 12 or 10 ]
example relAcc(0002-09891824205) is repeated 14 times then <seqNum> generates 14 that is <seqNum>14</seqNum>

again relAcc(0003-09891824205) <seqNum> 1 </seqNum> starts before this seqnum(1) starts <accEntry> has to be closed with </accEntry> tag

<relCust> is key
Can any one give me the solution

Thanks

Srini

Posted: Mon Oct 25, 2010 3:34 pm
by eostic
Hard to say...not understanding yet what you are looking for......so far it looks like it is working just fine. relEntry is inside of relList and relList hasn't closed yet.... after ALL the relEntry elements for that relList, you should see a close of </relList> and then finally a close of </accEntry>.

Are you expecting </accEntry> to close sooner?

Ernie

Posted: Mon Oct 25, 2010 6:31 pm
by prakashdasika
The opening and closing of tags should be defined properly in XML path expressions that we state with each column in the XMLOutput stage. How did you define them?

Are you using a transformer to manually create the tags?