ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Propagate Issues

Post new topic  Reply to topic
 Propagate Issues « View previous topic :: View next topic » 
Author Message
Gaya3
PostPosted: Mon Feb 18, 2008 2:46 am    Post subject: Propagate Issues Reply with quote

Jedi

Joined: 12 Sep 2006
Posts: 2493
Location: Boston, US

Hi

I have made a sample flow,

here is the ESQL, Here i am not getting second output,

I am getting Gayathri to the First Terminal Out, and for the second its prompting, No Data found in the message,

As you can see from the code that i am even copying the outputroot to a String,

Let me what went wrong here....

CREATE COMPUTE MODULE Propagate_Msg_Flow_Compute
CREATE FUNCTION Main() RETURNS BOOLEAN
BEGIN
CALL CopyMessageHeaders();
SET OutputRoot.XML.Name = 'Gayathri';
PROPAGATE TO TERMINAL 'Out' DELETE NONE;

CALL CopyEntireMessage();
PROPAGATE TO TERMINAL 'Out1' DELETE NONE;

RETURN TRUE;
END;

CREATE PROCEDURE CopyMessageHeaders() BEGIN
DECLARE I INTEGER 1;
DECLARE J INTEGER;
SET J = CARDINALITY(InputRoot.*[]);
WHILE I < J DO
SET OutputRoot.*[I] = InputRoot.*[I];
SET I = I + 1;
END WHILE;
END;

CREATE PROCEDURE CopyEntireMessage() BEGIN
SET OutputRoot.XML.Name = 'MQ Series';
END;
END MODULE;

Regards
Gayathri[/b]
_________________
Regards
Gayathri
-----------------------------------------------
Do Something Before you Die
Back to top
View user's profile Send private message
AJStar
PostPosted: Mon Feb 18, 2008 3:01 am    Post subject: Re: Propagate Issues Reply with quote

Acolyte

Joined: 27 Jun 2007
Posts: 64

Gaya3 wrote:

RETURN TRUE;


... by default propagates to Out terminal. You have already propagated to Out once using PROPAGATE.
Not sure if thats the issue, but just something that I found in the code.
_________________
Regards
AJ
Back to top
View user's profile Send private message
Gaya3
PostPosted: Mon Feb 18, 2008 3:14 am    Post subject: Reply with quote

Jedi

Joined: 12 Sep 2006
Posts: 2493
Location: Boston, US

Hi

I agree with you, but how can we handle this issue,

If i make Return False, i will get same message on the outputs

Regards
Gayathri
_________________
Regards
Gayathri
-----------------------------------------------
Do Something Before you Die
Back to top
View user's profile Send private message
AJStar
PostPosted: Mon Feb 18, 2008 3:29 am    Post subject: Reply with quote

Acolyte

Joined: 27 Jun 2007
Posts: 64

Try this

Code:
CREATE COMPUTE MODULE Propagate_Msg_Flow_Compute
CREATE FUNCTION Main() RETURNS BOOLEAN
BEGIN
CALL CopyMessageHeaders();
SET OutputRoot.XML.Name = 'Gayathri';
PROPAGATE TO TERMINAL 'Out1' DELETE NONE;

CALL CopyEntireMessage();
RETURN TRUE;
END;


By the way, I don't see anything wrong in ur code apart from the return true, which also on the other hand may not throw any error.
_________________
Regards
AJ
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Mon Feb 18, 2008 4:04 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

It's never never a good idea to call CopyHeaders AND CopyEntireMessage.

The Delete NONE is not going to remove anything.

So likely Gaya3 is making a big mess of the message tree by calling CopyEntireMessage.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
Gaya3
PostPosted: Mon Feb 18, 2008 4:13 am    Post subject: Reply with quote

Jedi

Joined: 12 Sep 2006
Posts: 2493
Location: Boston, US

Hi Jeff,

Usually i calls only one function, that is always Copy message headers.

Here its a sample flow,

Fine i have removed the same, but the logic is not working for me

I want the 2 different message to be routed to 2 different queues using propagate command

Regards
Gayathri
_________________
Regards
Gayathri
-----------------------------------------------
Do Something Before you Die
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Mon Feb 18, 2008 4:16 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

I guess the point is that you need to ensure that at PROPAGATE, the message tree looks correct for what you want it to be.

And you need to understand what the implications of the DELETE options you've specified will have on the message tree. This will help you to make sure the message tree looks correct for what you want it to be before the NEXT propagate.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
Bill.Matthews
PostPosted: Mon Feb 18, 2008 5:34 am    Post subject: Reply with quote

Master

Joined: 23 Sep 2003
Posts: 232
Location: IBM (Retired)

For the Propagate to Terminal statement - the name of the terminal in ESQL is all lowercase - out1 for example - not Out1.
_________________
Bill Matthews
Back to top
View user's profile Send private message
fschofer
PostPosted: Mon Feb 18, 2008 5:39 am    Post subject: Reply with quote

Knight

Joined: 02 Jul 2001
Posts: 524
Location: Mainz, Germany

Hi, maybe its a problem with the TerminalExpression
try out and out1 instead of Out and Out1

Quote:
TO TERMINAL clause
If the TO TERMINAL clause is present, TerminalExpression is evaluated. If the result is of type CHARACTER, a message is propagated to a terminal according to the rule:
‘nowhere’ : no propagation
‘failure’ : Failure
‘out’ : Out
‘out1' : Out1
‘out2' : Out2
‘out3' : Out3
‘out4’ : Out4


Greetings Frank
Back to top
View user's profile Send private message Send e-mail
Gaya3
PostPosted: Tue Feb 19, 2008 12:01 am    Post subject: Reply with quote

Jedi

Joined: 12 Sep 2006
Posts: 2493
Location: Boston, US

Hi Thanks to All,

Thanks to Jeff too,As you said the entire mqmd and message tree is getting deleted. its required to recreate the same

As bill said, The name of the terminal has to be in lower case

It looks good now

Regards
Gayathri
_________________
Regards
Gayathri
-----------------------------------------------
Do Something Before you Die
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Propagate Issues
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.