Author |
Message
|
sanhsi |
Posted: Tue Aug 20, 2013 6:01 am Post subject: UnorderedSet in AllElementsDelimited Message |
|
|
Novice
Joined: 26 Nov 2007 Posts: 12
|
Hi,
I am facing an issue in parsing input message of below format:
0;h1;h2;h3;h4
2;A1;A2;A3;A4
3;L1;L2;L3
5;T1;T2;T3;T4;T5
9;F1;F2
The incoming message have only one occurrance of 1st and last record and position is also fix.
Remaining 3 records can come multiple times and in any order.
To parse this message, I have created an MRM messageSet of TDS physical format.
The messageDefinition has a message with a headerType, an UnorderedSet group with 2nd, 3rd and 4th record and FooterType.
All the combinations are working fine but one.
If record 2 is coming after record 3 then it is throwing exception. The exception shows that if I keep record 2 after the record 3, while parsing the message record 3 type is trying to read all the message and in that processes throws exception that "NOT ALL BUFFER USED"
Can somebody help me resolve the issue please?
Please let me know if you need more information. |
|
Back to top |
|
 |
Vitor |
Posted: Tue Aug 20, 2013 6:31 am Post subject: Re: UnorderedSet in AllElementsDelimited Message |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
sanhsi wrote: |
Please let me know if you need more information. |
Which version of WMB; i.e. do you have access to DFDL or not? _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
mqjeff |
Posted: Tue Aug 20, 2013 6:31 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
Use DFDL not MRM.
Use a choice, not an unordered set. |
|
Back to top |
|
 |
sanhsi |
Posted: Tue Aug 20, 2013 6:43 am Post subject: |
|
|
Novice
Joined: 26 Nov 2007 Posts: 12
|
Thanks Vitor, mqjeff for quick response!
I am on wmb6.1 so no DFDL.
@mqjeff: when using choice, it is not able to parse anything after header record. If I check the parsed message in debug, it says unresolved choice for everything after header record! |
|
Back to top |
|
 |
mqjeff |
Posted: Tue Aug 20, 2013 6:47 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
sanhsi wrote: |
Thanks Vitor, mqjeff for quick response!
I am on wmb6.1 so no DFDL.
@mqjeff: when using choice, it is not able to parse anything after header record. If I check the parsed message in debug, it says unresolved choice for everything after header record! |
Use tags to resolve the choice. |
|
Back to top |
|
 |
sanhsi |
Posted: Wed Aug 21, 2013 1:21 am Post subject: |
|
|
Novice
Joined: 26 Nov 2007 Posts: 12
|
@mqjeff: Thanks a ton!!!
It worked! |
|
Back to top |
|
 |
|