Author |
Message
|
chanduy9 |
Posted: Tue Feb 12, 2002 9:20 am Post subject: |
|
|
Disciple
Joined: 28 Nov 2001 Posts: 177 Location: USA
|
Hi,
I am trying to find the length of the message which is in flat file(MRM), which is fixed length of records. I want to calculate number of records based on messagelength/rec.length, i know rec length, but when i am trying to find the length of incoming message i am getting NULL value. i tryed with InputBody and InputRoot, both are giving Null values...is there any way to find the length of message...thanks in advance.
Chandra. |
|
Back to top |
|
 |
kirani |
Posted: Tue Feb 12, 2002 10:16 am Post subject: |
|
|
Jedi Knight
Joined: 05 Sep 2001 Posts: 3779 Location: Torrance, CA, USA
|
What is your input Message layout? What ESQL are you using now to get the length of the message? If you are reading input as BLOB you can use following ESQL to get the message length,
DECLARE MSGLEN INT;
SET MSGLEN = (LENGTH(CAST(InputRoot."BLOB"."BLOB" AS CHAR)) - 3)/2;
Kiran
|
|
Back to top |
|
 |
chanduy9 |
Posted: Tue Feb 12, 2002 10:46 am Post subject: |
|
|
Disciple
Joined: 28 Nov 2001 Posts: 177 Location: USA
|
Hi,
I am getting message as a flat file, i am using MRM domain. i am using follwoing ESQL..
SET LEN=LENGTH(InputBody);
i tried with InputRoot also..but no luck.
Thanks,
Chandra.
|
|
Back to top |
|
 |
kirani |
Posted: Tue Feb 12, 2002 1:21 pm Post subject: |
|
|
Jedi Knight
Joined: 05 Sep 2001 Posts: 3779 Location: Torrance, CA, USA
|
How does your message definition look like in MRM message set? Do you have message defined for each record?
Kiran
|
|
Back to top |
|
 |
chanduy9 |
Posted: Tue Feb 12, 2002 3:43 pm Post subject: |
|
|
Disciple
Joined: 28 Nov 2001 Posts: 177 Location: USA
|
Hi,
i defined message set as repeatable...like every record will repeat 'n' number of times.
Chandra. |
|
Back to top |
|
 |
mpuetz |
Posted: Tue Feb 12, 2002 3:47 pm Post subject: |
|
|
Centurion
Joined: 05 Jul 2001 Posts: 149 Location: IBM/Central WebSphere Services
|
Hi,
try this
SET LEN = LENGTH(BITSTREAM(InputBody));
_________________ Mathias Puetz
IBM/Central WebSphere Services
WebSphere Business Integration Specialist |
|
Back to top |
|
 |
|