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 » Cretae XML message using schema ESQL Procedure(Reference)

Post new topic  Reply to topic
 Cretae XML message using schema ESQL Procedure(Reference) « View previous topic :: View next topic » 
Author Message
deepak_paul
PostPosted: Sat May 08, 2010 11:06 am    Post subject: Cretae XML message using schema ESQL Procedure(Reference) Reply with quote

Centurion

Joined: 04 Oct 2008
Posts: 147
Location: US

Below is my code:

Code:
CREATE COMPUTE MODULE HeaderReference_Compute
   CREATE FUNCTION Main() RETURNS BOOLEAN
   BEGIN
        DECLARE rOutRefXML REFERENCE TO OutputRoot.XMLNSC.TCRMService;
   DECLARE rInRefMRM REFERENCE TO InputRoot.MRM;
        CALL CreateTransactionHeader(rInRefMRM, rOutRefXML);
        RETURN TRUE;
   END;

   CREATE PROCEDURE CopyEntireMessage() BEGIN
      SET OutputRoot = InputRoot;
   END;
END MODULE;

CREATE PROCEDURE CreateTransactionHeader(IN rInRefMRM REFERENCE,INOUT rOutRefXML REFERENCE) BEGIN
SET rOutRefXML.RequestControl.DWLControl.requesterTime = CAST(CURRENT_TIMESTAMP AS CHAR);
END;



I am getting output message with no content in it. Please guide.[/code]
_________________
Regards
Paul
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Sat May 08, 2010 11:13 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

Bad step/design. If you want to create a generic function / procedure you need to call it passing the reference and not declare the reference in it.

Have fun
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
rekarm01
PostPosted: Sat May 08, 2010 12:16 pm    Post subject: Re: Create XML message using schema ESQL Procedure ... Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 1415

deepak_paul wrote:
Code:
CREATE COMPUTE MODULE HeaderReference_Compute
   CREATE FUNCTION Main() RETURNS BOOLEAN
   BEGIN
      DECLARE rOutRefXML REFERENCE TO OutputRoot.XMLNSC.TCRMService;

OutputRoot is empty, here.
rOutRefXML does not refer to an existing element.

deepak_paul wrote:
Code:
      DECLARE rInRefMRM REFERENCE TO InputRoot.MRM;
      CALL CreateTransactionHeader(rInRefMRM, rOutRefXML);
      RETURN TRUE;
   END;


[Edit: Fixed typos]
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 » Cretae XML message using schema ESQL Procedure(Reference)
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.