Author |
Message
|
nheng |
Posted: Fri Jun 26, 2009 2:09 am Post subject: Why UUIDASBLOB is duplication in same code? |
|
|
 Apprentice
Joined: 07 Dec 2007 Posts: 39
|
DECLARE i INTEGER 1;
DECLARE count INTEGER;
SET count = CARDINALITY(InputRoot.XML.Request.Body.IntStmtReq.AcctInfo[]);
WHILE i <= count DO
CALL CopyMessageHeaders();
SET OutputRoot.MQMD.Format = 'X_ETBGRQ';
SET OutputRoot.MQMD.CorrelId=InputRoot.MQMD.MsgId;
SET OutputRoot.MQMD.MsgId= (x'5040000000000000' || UUIDASBLOB);
SET OutputRoot.XML.Request.Body.IntStmtReq = InputRoot.XML.Request.Body.IntStmtReq.AcctInfo[i];
PROPAGATE;
SET i = i + 1;
END WHILE;
RETURN FALSE;
Result:All output message after propagating.CorrelId of all message is same
Question: Has the another way to generate uniqe id of all output message via function in esql?
*** |
|
Back to top |
|
 |
AkankshA |
Posted: Fri Jun 26, 2009 2:25 am Post subject: |
|
|
 Grand Master
Joined: 12 Jan 2006 Posts: 1494 Location: Singapore
|
Do not play around much with message id and correlId....
In this case all the messages propagated will have same msg id which is not valid as per standards..
rather click on generate new msgid and correl id of MQOutput node and let the toool handle it. _________________ Cheers |
|
Back to top |
|
 |
AkankshA |
Posted: Fri Jun 26, 2009 2:30 am Post subject: Re: Why UUIDASBLOB is duplication in same code? |
|
|
 Grand Master
Joined: 12 Jan 2006 Posts: 1494 Location: Singapore
|
Coming to duplicacy which u mentioned....
nheng wrote: |
WHILE i <= count DO
CALL CopyMessageHeaders();
SET OutputRoot.MQMD.Format = 'X_ETBGRQ';
SET OutputRoot.MQMD.CorrelId=InputRoot.MQMD.MsgId;
SET OutputRoot.MQMD.MsgId= (x'5040000000000000' || UUIDASBLOB);
SET OutputRoot.XML.Request.Body.IntStmtReq = InputRoot.XML.Request.Body.IntStmtReq.AcctInfo[i];
PROPAGATE;
SET i = i + 1;
END WHILE;
RETURN FALSE;
Result:All output message after propagating.CorrelId of all message is same
Question: Has the another way to generate uniqe id of all output message via function in esql?
*** |
Won't InputRoot[/b].MQMD.MsgId be same for entire loop.... you are changing OutputRoot and not InputRoot _________________ Cheers |
|
Back to top |
|
 |
nheng |
Posted: Fri Jun 26, 2009 2:42 am Post subject: OK |
|
|
 Apprentice
Joined: 07 Dec 2007 Posts: 39
|
AkankshA wrote: |
Do not play around much with message id and correlId....
In this case all the messages propagated will have same msg id which is not valid as per standards..
rather click on generate new msgid and correl id of MQOutput node and let the toool handle it. |
Ok I will remember.Almost thank. |
|
Back to top |
|
 |
nheng |
Posted: Fri Jun 26, 2009 2:58 am Post subject: Re: Why UUIDASBLOB is duplication in same code? |
|
|
 Apprentice
Joined: 07 Dec 2007 Posts: 39
|
AkankshA wrote: |
Coming to duplicacy which u mentioned....
nheng wrote: |
WHILE i <= count DO
CALL CopyMessageHeaders();
SET OutputRoot.MQMD.Format = 'X_ETBGRQ';
SET OutputRoot.MQMD.CorrelId=InputRoot.MQMD.MsgId;
SET OutputRoot.MQMD.MsgId= (x'5040000000000000' || UUIDASBLOB);
SET OutputRoot.XML.Request.Body.IntStmtReq = InputRoot.XML.Request.Body.IntStmtReq.AcctInfo[i];
PROPAGATE;
SET i = i + 1;
END WHILE;
RETURN FALSE;
Result:All output message after propagating.CorrelId of all message is same
Question: Has the another way to generate uniqe id of all output message via function in esql?
*** |
Won't InputRoot[/b].MQMD.MsgId be same for entire loop.... you are changing OutputRoot and not InputRoot |
Hey After i create mqoutnode and inputnode in same messageflow (I already clicked reset msgid).Msgid still duplication in same messageflow. |
|
Back to top |
|
 |
AkankshA |
Posted: Fri Jun 26, 2009 3:32 am Post subject: Re: Why UUIDASBLOB is duplication in same code? |
|
|
 Grand Master
Joined: 12 Jan 2006 Posts: 1494 Location: Singapore
|
nheng wrote: |
Hey After i create mqoutnode and inputnode in same messageflow (I already clicked reset msgid).Msgid still duplication in same messageflow. |
How are you verifying that it has not generated new msg id or correl id ?
On MQOutput node, if you check "new message ID" and "new correlation ID" radio button then any message that will be put to MQ queue through that node, would have a new message ID and Correlation id BUT thats valid only once message is put to output queue. In case the output terminal is attached to further flow, you will see older msg ID and correl ID ....
ONLY msg in queue ll get new msg id and correl ID _________________ Cheers |
|
Back to top |
|
 |
nheng |
Posted: Sun Jun 28, 2009 7:33 pm Post subject: Re: Why UUIDASBLOB is duplication in same code? |
|
|
 Apprentice
Joined: 07 Dec 2007 Posts: 39
|
AkankshA wrote: |
nheng wrote: |
Hey After i create mqoutnode and inputnode in same messageflow (I already clicked reset msgid).Msgid still duplication in same messageflow. |
How are you verifying that it has not generated new msg id or correl id ?
On MQOutput node, if you check "new message ID" and "new correlation ID" radio button then any message that will be put to MQ queue through that node, would have a new message ID and Correlation id BUT thats valid only once message is put to output queue. In case the output terminal is attached to further flow, you will see older msg ID and correl ID ....
ONLY msg in queue ll get new msg id and correl ID |
I checked it.But It generated new MsgID and CorrelID be one uniq number. |
|
Back to top |
|
 |
|