Author |
Message
|
TDS_tds_tds |
Posted: Thu Jul 31, 2003 4:23 pm Post subject: TDS Multiple Records and <CR><LF> handling |
|
|
 Novice
Joined: 31 Jul 2003 Posts: 16
|
I am having problems in setting properties for a TDS format message set.
Here is the message format
name,address,id
name,address,id
name,address,id
(above set repeats so on)
(assume <CR><LF> after each line)
I defined these elements into a compound type (say MyInfo_Type)
I created an element of this type ( say MyInfo_Elem)
I created a message(MyInfo_Msg) using SmartGuide and added MyInfo_Elem to it.
In the Types section for this message - MyInfo_Msg,
properties are defined as follows
Type Composition - Sequence
Type Content - Closed
Data element Seperation - All Elements Delimited
Delimiter - <CR><LF>
In Connection tab for this message type, repeat is set as yes.
In TDS tab, Repeating Element Delimiter is set as <CR><LF>
Also
In order to indicate ',' as delimiter between the fields, following properties
were set on MyInfo_Type
Type Composition - Sequence
Type Content - Closed
Data element Seperation - All Elements Delimited
Delimiter= ,
To check the above, I created a simple message flow with a trace node.....and
tested with the input message :
John,Dallas,123
Jackson,Atlanta,7865
Hillary,Tokyo,4545454
I checked the trace file .....it is showing that
0x1000021)MRM = (
(0x1000013)MyInfo_Elem = (
(0x300000B)name = 'John'
(0x300000B)address = 'Dallas'
(0x300000B)id = '123
Jackson,Atlanta,7865
Hillary,Tokyo,4545454'
For some reason, it is not parsing from the second records.....how to solve this ?
if this is not the general procedure .....pls let me know how to develop it.
many thanks in adv
[/b] |
|
Back to top |
|
 |
HugoB |
Posted: Fri Aug 01, 2003 2:12 am Post subject: |
|
|
Acolyte
Joined: 26 Jun 2001 Posts: 67
|
Are you sure you have a <cr><lf> in your test message ??
How do you put the message on the input queue ?? (rfhutil ??)
Maybe try this
Delimiter - <CR><LF>,
And i don't think you need to define things in the connection tab
at this moment, but this is hazy to me too.
Be sure you get the <cr><lf> in the flow !!! |
|
Back to top |
|
 |
Craig B |
Posted: Fri Aug 01, 2003 3:06 am Post subject: |
|
|
Partisan
Joined: 18 Jun 2003 Posts: 316 Location: UK
|
From what you have described in your definitions then from first observations this should work. The last update has a point in that maybe the carriage return and line feed characters did not make it into the message. Some putting applications such as mqsiput kindly strip out carriage returns and line feeds and replace them with just a line feed character, similar to the XML parser. It would be worth you browsing the message on the queue before it enters the flow to ensure you still have x'0D0A' characters and not just x'0A'. _________________ Regards
Craig |
|
Back to top |
|
 |
TDS_tds_tds |
Posted: Fri Aug 01, 2003 9:06 am Post subject: |
|
|
 Novice
Joined: 31 Jul 2003 Posts: 16
|
Thanks for the response.
I am not using any ibm supplied tools to put those messages......
I am using an application which dumps the messages from a file....
this file contains messages as specified in my last posting.
I am sure someone in this group did worked on this type of TDS Message Format ......... I think I made a simple mistake somewhere in the properties....
Please post your valuable comments .....this thing is holding me off.... |
|
Back to top |
|
 |
kirank |
Posted: Fri Aug 01, 2003 10:01 am Post subject: |
|
|
 Centurion
Joined: 10 Oct 2002 Posts: 136 Location: California
|
You said that In Connection tab for this message type, repeat is set as yes. Have you set Min Occurs property to '1'?
Thanks
Kiran Kanetkar
Solution Architect |
|
Back to top |
|
 |
TDS_tds_tds |
Posted: Fri Aug 01, 2003 10:36 am Post subject: |
|
|
 Novice
Joined: 31 Jul 2003 Posts: 16
|
I just tried setting it to 1....did not help ....
any other option you guys can think abt ......
Craig,
how do i check that message has x'0D0A' characters or x'0A' characters ???
I did use amqsbcg to browse the message ..... i am not quite sure if the above mentioned characters are in there.... |
|
Back to top |
|
 |
kirani |
Posted: Fri Aug 01, 2003 10:50 am Post subject: |
|
|
Jedi Knight
Joined: 05 Sep 2001 Posts: 3779 Location: Torrance, CA, USA
|
What is your input message's CCSID and Encoding set to? Can you read your input message as BLOB and print ${Root} in a trace node, which will give us input message in HEX Format. We can then verify if it's putting <CR><LF> in the message. _________________ Kiran
IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries
|
|
Back to top |
|
 |
kirank |
Posted: Fri Aug 01, 2003 11:06 am Post subject: |
|
|
 Centurion
Joined: 10 Oct 2002 Posts: 136 Location: California
|
If you are passing the values to MRM elements in a compute node, make sure that you use a While loop with index to pass values to multiple occurances of the same MRM field.
Thanks
Kiran Kanetkar
Solution Architect |
|
Back to top |
|
 |
Tibor |
Posted: Mon Aug 04, 2003 7:00 am Post subject: |
|
|
 Grand Master
Joined: 20 May 2001 Posts: 1033 Location: Hungary
|
TripleTDS,
You should to create a slightly complex MRM structure:
- 'type1' - for each line
- 'msg2' - for the message and add element type1 (additionally, ConfigMgr creating a new type named 't_msg2')
Then, set 't_msg2'
- Connection/Repeat: Yes
- TDS/Repeating Element Dilimiter: <CR><LF>
Tibor |
|
Back to top |
|
 |
|