Author |
Message
|
BrettAnnand |
Posted: Thu Apr 24, 2003 6:14 pm Post subject: ResetContentDescriptor |
|
|
Newbie
Joined: 24 Apr 2003 Posts: 3
|
I have 3 different types of message in a queue feeding to 3 parallel ResetContentDescriptor to route to 3 different queues. Will this work or anyone has better suggestions?
Thanks. |
|
Back to top |
|
 |
kirani |
Posted: Thu Apr 24, 2003 6:48 pm Post subject: |
|
|
Jedi Knight
Joined: 05 Sep 2001 Posts: 3779 Location: Torrance, CA, USA
|
Could you please explain your requirement in more details.
Do you want to route same message to all 3 destinations or depending on the input message you want to route it to a specific destination? _________________ 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 |
|
 |
BrettAnnand |
Posted: Thu Apr 24, 2003 7:03 pm Post subject: |
|
|
Newbie
Joined: 24 Apr 2003 Posts: 3
|
For example:
Input Data type 1
FIELD1(length10)FIELD2(length20)FIELD3(length5)
Input Data type 2
FIELD1(length2)FIELD2(length8)
Input Data type 3
FIELD1(length6)FIELD2(length20)FIELD3(length1)FIELD4(length8)FIELD5(length12)
All these input data will need to go to different queues. For example, Input Data type 1 will need to go to queue1
Input Data type 2 will need to go to queue2
Input Data type 3 will need to go to queue3
Thanks |
|
Back to top |
|
 |
kirani |
Posted: Thu Apr 24, 2003 7:23 pm Post subject: |
|
|
Jedi Knight
Joined: 05 Sep 2001 Posts: 3779 Location: Torrance, CA, USA
|
There are multiple ways to do this:
1) Read message as BLOB and then in a compute node check for the input message length using LENGTH function, if the length is 35 then route message to queue1, if the length is 10 then route the message to queue2, if the length is 47 then route the message to queue3.
2) Client application will set some application identifier to indicate whether it's inputDataType1, 2 or 3. Based on this field you can route the message to different queues. _________________ 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 |
|
 |
BrettAnnand |
Posted: Thu Apr 24, 2003 7:35 pm Post subject: |
|
|
Newbie
Joined: 24 Apr 2003 Posts: 3
|
Would you please give the esql for the length function. I am not very versatile with the esql
Also what about using the check node prior to RCD?
Thanks. |
|
Back to top |
|
 |
kirani |
Posted: Thu Apr 24, 2003 7:49 pm Post subject: |
|
|
Jedi Knight
Joined: 05 Sep 2001 Posts: 3779 Location: Torrance, CA, USA
|
Well in either case you don't need RCD or Check node.
Try this ESQL:
Code: |
DECLARE LEN INT;
SET LEN = LENGTH(CAST(InputBody."BLOB"."BLOB" as CHAR CCSID InputRoot.MQMD.CodedCharSetId));
IF ( LEN = 35) THEN
-- Set DestinationList to queue1
ELSEIF ....
...
END IF;
|
_________________ 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 |
|
 |
kiestrada |
Posted: Thu Apr 24, 2003 8:36 pm Post subject: |
|
|
Novice
Joined: 19 Jun 2002 Posts: 12
|
Oh great I have a rather similar situation.
I have multiple input data formats, but instead of directly routing to queue, I need to perform filter and reformat before going to different queues.
For example:
Input Data type 1
FIELD1(length10)FIELD2(length20)FIELD3(length5)
{JUST SEND THIS DATA TYPE TO QUEUE1}
Input Data type 2
FIELD1(length2)FIELD2(length8),
{IF FIELD1=AA SEND DATA TYPE TO QUEUEAA, AND IF FIELD1=BB, THEN SEND TO QUEUEBB}
Input Data type 3
FIELD1(length6)FIELD2(length20)FIELD3(length1)FIELD4(length8)FIELD5(length12)
{SEND THIS DATA TYPE TO QUEUE3 AND QUEUE4}
Any solution?
Thanks |
|
Back to top |
|
 |
|