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 » MESSAGE IS GETTING INTO O/P QUEUE AS IT IS, WHY?

Post new topic  Reply to topic
 MESSAGE IS GETTING INTO O/P QUEUE AS IT IS, WHY? « View previous topic :: View next topic » 
Author Message
venugp
PostPosted: Wed Sep 18, 2002 10:57 am    Post subject: MESSAGE IS GETTING INTO O/P QUEUE AS IT IS, WHY? Reply with quote

Apprentice

Joined: 03 Sep 2002
Posts: 31

Hi,
I am trying to execute one flow with the XML message as input and 5 nodes total, INPUTNODE----->TRACENODE------>COMPUTENODE--->
TRACENODE--->OUTPUTNODE.
In input node properties i am mentioning domain name as XML and leaving reamining blank, trace node properties i am just mentioning destination as usertrace and leaving reamining fileds blank, In the compute node i am doing some translation and transformation using esql, then other trace node is same as the first one.
Some how the same is getting populated into the output queue and i am not able to figure out exactly where i am doing wrong with the above said flow.
Can any body help me with this problem.
Thanks,
venu.
Back to top
View user's profile Send private message
lbrett
PostPosted: Wed Sep 18, 2002 11:58 am    Post subject: Reply with quote

Novice

Joined: 24 Jan 2002
Posts: 20

If you can post the ESQL in your compute node, that maybe helpful.
Back to top
View user's profile Send private message
kirani
PostPosted: Wed Sep 18, 2002 12:01 pm    Post subject: Reply with quote

Jedi Knight

Joined: 05 Sep 2001
Posts: 3779
Location: Torrance, CA, USA

Venu,

What is your compute mode set to?
_________________
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
View user's profile Send private message Visit poster's website
venugp
PostPosted: Wed Sep 18, 2002 12:08 pm    Post subject: Reply with quote

Apprentice

Joined: 03 Sep 2002
Posts: 31

Kiran,
Mu compute node set to message first in the advanced tab then i tried with localenvironmentandmessage but still not bale to figure out where i am missing. Here i am aslo posting my esql please correct me if i am making any mistakes.
Thanks,
venu.

SET OutputRoot = InputRoot;
-- Enter SQL below this line. SQL above this line might be regenerated, causing any modifications to be lost.

declare I INTEGER;
SET I = 1;
WHILE I < CARDINALITY(InputRoot.XML.contact admin.HNA_VENDOR_SEG.HAM.LOCDESC_SEG.*[]) DO

SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].DUNSID =
InputRoot.XML.Transaction.HNA_VENDOR_SEG.SETID ||
InputRoot.XML.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_DUNS_SEG.STD_ID_NUM
|| InputRoot.XML.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].VNDR_LOC;

SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].CompanyName = InputRoot.XML.Transaction.HNA_VENDOR_SEG.NAME1;
--DECLARE VENDOR_STATUS CHARACTER;
--SET VENDOR_STATUS = InputRoot.XML.MsgData.Transaction.HNA_VENDOR_SEG.VENDOR_STATUS;
if (InputRoot.XML.MsgData.Transaction.HNA_VENDOR_SEG.VENDOR_STATUS = 'A' and
InputRoot.XML.Transaction.HNA_VENDOR_SEG.VENDOR_STATUS_PO = 'Y' and
InputRoot.XML.Transaction.HNA_VENDOR_SEG.HNA_VNDRLOC_SEG.EFF_STATUS = 'A')THEN
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Status = 'A';
else
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Status = 'I';
end if;

SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Type = 'AS';
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].IsSupplier = '1';
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Manufacturing = '0';
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].OperationMode =
InputRoot.XML.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.PSCAMA.AUDIT_ACTN;

--Address segment
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Address1 =
InputRoot.XML.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.ADDRESS1
|| InputRoot.XML.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.ADDRESS2;

SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Address2 =
InputRoot.XML.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.ADDRESS3
|| InputRoot.XML.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.ADDRESS4;


SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.City = InputRoot.XML.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.CITY;
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.State = InputRoot.XML.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.STATE;
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.zipCode = InputRoot.XML.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.POSTAL;
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Country = InputRoot.XML.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.COUNTRY;
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.OperationMode = InputRoot.XML.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.PSCAMA.AUDIT_ACTN;

--Contact Segment
declare m INTEGER;
SET m = 1;
WHILE m < CARDINALITY(InputRoot.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG.*[]) DO
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].Name =
InputRoot.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG[m].CONTACT_NAME;
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].Title =
InputRoot.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG[m].TITLE;
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].EmailAddress =
InputRoot.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG[m].EMAILID;

declare PhoneType CHARACTER;
DECLARE N INTEGER;
DECLARE Phone_No CHARACTER;
WHILE N < CARDINALITY(InputRoot.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG.HNA_CTPHN_SEG.*[]) DO

SET PhoneType =InputRoot.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG[m].HNA_CTPHN_SEG[N].PHONE_TYPE;
set Phone_No=InputRoot.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG[m].HNA_CTPHN_SEG[N].COUNTRY_CODE
|| InputRoot.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG[m].HNA_CTPHN_SEG[N].PHONE
|| InputRoot.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG[m].HNA_CTPHN_SEG[N].EXTENSION;

IF PhoneType = 'BUSN' then
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].TelNumber = Phone_No;
end if;
if PhoneType = 'FAX' then
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].FaxNumber = Phone_No;
end if;
if PhoneType = 'CELL' then
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].CellPhone = Phone_No;
end if;
if PhoneType = 'PAGER1' then
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].PagerNumber = Phone_No;
else
if PhoneType = 'PAGER2' then
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].PagerNumber = Phone_No;
end if;
end if;
set N=N+1;
end while;
SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].EmailAddress =
InputRoot.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG[m].PSCAMA_AUDIT_ACTN;
SET m = m+1;
END WHILE;
SET I = I+1;
END WHILE;
Back to top
View user's profile Send private message
kirani
PostPosted: Wed Sep 18, 2002 12:18 pm    Post subject: Reply with quote

Jedi Knight

Joined: 05 Sep 2001
Posts: 3779
Location: Torrance, CA, USA

Venu,

I see that you are generating new XML output message, so you should select Copy Message Headers only in your compute node. Set your compute mode to Message only.

At first glance I found one mistake in your code:
WHILE I < CARDINALITY(InputRoot.XML.Transaction.HNA_VENDOR_SEG.HAM.LOCDESC_SEG.*[]) DO

You mistyped the Transaction tag name.
_________________
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
View user's profile Send private message Visit poster's website
venugp
PostPosted: Wed Sep 18, 2002 12:55 pm    Post subject: Reply with quote

Apprentice

Joined: 03 Sep 2002
Posts: 31

Kiran,
I have selected the copy message headers and i set the compute node to message but i am not getting anything into the output queue, the queue is showing 1 message with 0 data length.
Actually i am trying to build the output message from the input message with by applying business rules, i am not sure which radio button to select in this caser but i have tried with both options.
with the entire message i am getting the XML message as it is and with the headres only with 0 data length.
I have corrected the typo error in my code and thanks for that.
When i selectd the copy message headers only there is additional code in compute node like this.
DECLARE I INTEGER;
SET I = 1;
WHILE I < CARDINALITY(InputRoot.*[]) DO
SET OutputRoot.*[I] = InputRoot.*[I];
SET I=I+1;
END WHILE;
Help me out Kiran.
Thanks,
venu.
Back to top
View user's profile Send private message
kirani
PostPosted: Wed Sep 18, 2002 1:23 pm    Post subject: Reply with quote

Jedi Knight

Joined: 05 Sep 2001
Posts: 3779
Location: Torrance, CA, USA

Venu,
Now that you are getting output message of length 0, I think, your control is not going inside the while loop. This could be because of incorrect element name in WHILE loop.
I think I found more errors in your code. Could you post sample input message here so that we can verify your code against input message.
_________________
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
View user's profile Send private message Visit poster's website
philip.baker
PostPosted: Wed Sep 18, 2002 1:35 pm    Post subject: Reply with quote

Voyager

Joined: 21 Mar 2002
Posts: 77
Location: Baker Systems Consulting, Inc. - Tampa

Try replacing:

Quote:
declare I INTEGER;
SET I = 1;
WHILE I < CARDINALITY(InputRoot.XML.contact admin.HNA_VENDOR_SEG.HAM.LOCDESC_SEG.*[]) DO


with:
declare I INTEGER;
SET I = 1;
IF (InputRoot.XML.Transaction.HNA_VENDOR_SEG.HAM.LOCDESC_SEG IS NOT NULL) THEN
WHILE I < CARDINALITY (InputRoot.XML.Transaction.HNA_VENDOR_SEG.HAM.LOCDESC_SEG[]) DO
--SET Code
-- Increment I
END WHILE;
END IF;

I also think you are not getting inside your WHILE loop. You need to set up some testing within the flow to make sure.

Phil
Back to top
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger
venugp
PostPosted: Wed Sep 18, 2002 2:10 pm    Post subject: Reply with quote

Apprentice

Joined: 03 Sep 2002
Posts: 31

Kiran,
I am psoting my sample message here, it's little bit big message but if you have some time please help me out.
Thanks,
venu.
<?xml version='1.0'?>
</HNA_VENDOR>
<MsgData>
<Transaction>
<HNA_VENDOR_SEG class="R">
<SETID>SHARE</SETID>
<VENDOR_ID>0000000055</VENDOR_ID>
<NAME1>Vendor ID within range for HCM</NAME1>
<VENDOR_STATUS>A</VENDOR_STATUS>
<VNDR_STATUS_PO>Y</VNDR_STATUS_PO>
<DEFAULT_LOC>L1</DEFAULT_LOC>
<HNA_LOCDESC_SEG class="R">
<SETID>SHARE</SETID>
<VENDOR_ID>0000000055</VENDOR_ID>
<VNDR_LOC>L1</VNDR_LOC>
<DESCR>Loc1</DESCR>
<HNA_VNDRLOC_SEG class="R">
<SETID>SHARE</SETID>
<VENDOR_ID>0000000055</VENDOR_ID>
<VNDR_LOC>L1</VNDR_LOC>
<EFFDT>2002-09-13</EFFDT>
<EFF_STATUS>A</EFF_STATUS>
<ADDR_SEQ_NUM_ORDR>1</ADDR_SEQ_NUM_ORDR>
<BUYER_ID></BUYER_ID>
<DISP_METHOD></DISP_METHOD>
<FREIGHT_TERMS></FREIGHT_TERMS>
<MATCH_CNTRL_ID></MATCH_CNTRL_ID>
<SHIP_TYPE_ID></SHIP_TYPE_ID>
<HNA_DUNS_SEG class="R">
<SETID>SHARE</SETID>
<VENDOR_ID>0000000055</VENDOR_ID>
<VNDR_LOC>L1</VNDR_LOC>
<EFFDT>2002-09-13</EFFDT>
<STD_ID_NUM_QUAL>DNS</STD_ID_NUM_QUAL>
<STD_ID_NUM>223344</STD_ID_NUM>
<STD_ID_SETID></STD_ID_SETID>
</HNA_DUNS_SEG>
<PSCAMA class="R">
<AUDIT_ACTN>A</AUDIT_ACTN>
</PSCAMA>
<HNA_VNDADDR_SEG class="R">
<SETID>SHARE</SETID>
<VENDOR_ID>0000000055</VENDOR_ID>
<ADDRESS_SEQ_NUM>1</ADDRESS_SEQ_NUM>
<EFFDT></EFFDT>
<EFF_STATUS>A</EFF_STATUS>
<ADDRESS1>Line 1</ADDRESS1>
<ADDRESS2>Line 2</ADDRESS2>
<ADDRESS3>Line 3</ADDRESS3>
<ADDRESS4></ADDRESS4>
<CITY>Columbus</CITY>
<STATE>OH</STATE>
<POSTAL>12345</POSTAL>
<COUNTRY>USA</COUNTRY>
<HNA_ADDRPHN_SEG class="R">
<SETID>SHARE</SETID>
<VENDOR_ID>0000000055</VENDOR_ID>
<ADDRESS_SEQ_NUM>1</ADDRESS_SEQ_NUM>
<EFFDT>2002-09-13</EFFDT>
<PHONE_TYPE>FAX</PHONE_TYPE>
<COUNTRY_CODE>001</COUNTRY_CODE>
<PHONE>425/654-7894</PHONE>
<EXTENSION></EXTENSION>
</HNA_ADDRPHN_SEG>
<PSCAMA class="R">
<AUDIT_ACTN>A</AUDIT_ACTN>
</PSCAMA>
<HNA_VNDCNT_SEG class="R">
<SETID>SHARE</SETID>
<VENDOR_ID>0000000055</VENDOR_ID>
<CNTCT_SEQ_NUM>1</CNTCT_SEQ_NUM>
<EFFDT>2002-09-13</EFFDT>
<ADDRESS_SEQ_NUM>1</ADDRESS_SEQ_NUM>
<EFF_STATUS>A</EFF_STATUS>
<CONTACT_NAME>Con 1</CONTACT_NAME>
<CONTACT_TITLE>Mr.</CONTACT_TITLE>
<URL></URL>
<EMAILID></EMAILID>
<HNA_CTPHN_SEG class="R">
<SETID>SHARE</SETID>
<VENDOR_ID>0000000055</VENDOR_ID>
<CNTCT_SEQ_NUM>1</CNTCT_SEQ_NUM>
<EFFDT>2002-09-13</EFFDT>
<PHONE_TYPE>BUSN</PHONE_TYPE>
<COUNTRY_CODE>001</COUNTRY_CODE>
<PHONE>456/352-1247</PHONE>
<EXTENSION></EXTENSION>
</HNA_CTPHN_SEG>
</HNA_VNDCNT_SEG>
<PSCAMA class="R">
<AUDIT_ACTN>A</AUDIT_ACTN>
</PSCAMA>
</HNA_VNDADDR_SEG>
<PSCAMA class="R">
<AUDIT_ACTN>A</AUDIT_ACTN>
</PSCAMA>
</HNA_VNDRLOC_SEG>
<PSCAMA class="R">
<AUDIT_ACTN>A</AUDIT_ACTN>
</PSCAMA>
</HNA_LOCDESC_SEG>
<PSCAMA class="R">
<AUDIT_ACTN>A</AUDIT_ACTN>
</PSCAMA>
</HNA_VENDOR_SEG>
<PSCAMA class="R">
<LANGUAGE_CD>ENG</LANGUAGE_CD>
<AUDIT_ACTN>A</AUDIT_ACTN>
<BASE_LANGUAGE_CD>ENG</BASE_LANGUAGE_CD>
<MSG_SEQ_FLG></MSG_SEQ_FLG>
<PROCESS_INSTANCE>0</PROCESS_INSTANCE>
<PUBLISH_RULE_ID></PUBLISH_RULE_ID>
<MSGNODENAME></MSGNODENAME>
</PSCAMA>
</Transaction>
</MsgData>
</HNA_VENDOR>
Back to top
View user's profile Send private message
philip.baker
PostPosted: Wed Sep 18, 2002 2:41 pm    Post subject: Reply with quote

Voyager

Joined: 21 Mar 2002
Posts: 77
Location: Baker Systems Consulting, Inc. - Tampa

venugp,

Edit the first </HNA_VENDOR> of your message to be <HNA_VENDOR>, save to an XML file and try to display the file using a Browser. You will see where you have made errors in the ESQL of your message flow.

Quote:
WHILE I < CARDINALITY(InputRoot.XML.Transaction.HNA_VENDOR_SEG.HAM.LOCDESC_SEG.*[]) DO


should be :

WHILE I <= CARDINALITY(InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[]) DO

You must check all your 'InputRoot' type paths to make sure they conform to your inbound message structure otherwise MQSI can not find the elements.

Regards,
Phil


Last edited by philip.baker on Wed Sep 18, 2002 2:59 pm; edited 2 times in total
Back to top
View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger
kirani
PostPosted: Wed Sep 18, 2002 2:52 pm    Post subject: Reply with quote

Jedi Knight

Joined: 05 Sep 2001
Posts: 3779
Location: Torrance, CA, USA

There are few typo errors in your input message. Anyway I found following problems in your code..
1. In many places you are missing .XML. in your code after InputRoot.
2. Your message shows that the outer tag name is <HNA_VENDOR>, in your code you are using <Transaction> as outermost tag.
3. Your while loops are not correct. The [] wasn't at the correct place.

I have made few changes to the ESQL code (based on some assumptions from input message), I am not sure whether this will work or not. You will have to go thru line by line and see if you are referring to correct element name and level.

Code:

declare I INTEGER;
SET I = 1;
DECLARE ICNT = CARDINALITY(InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[]);
WHILE (I <= ICNT) DO

   SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].DUNSID =
      InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.SETID ||
      InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_DUNS_SEG.STD_ID_NUM ||
      InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].VNDR_LOC;

   SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].CompanyName = InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.NAME1;
   --DECLARE VENDOR_STATUS CHARACTER;
   --SET VENDOR_STATUS = InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.VENDOR_STATUS;

   if (InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.VENDOR_STATUS = 'A' and
      InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.VENDOR_STATUS_PO = 'Y' and
      InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_VNDRLOC_SEG.EFF_STATUS = 'A')THEN
      SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Status = 'A';
   else
      SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Status = 'I';
   end if;

   SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Type = 'AS';
   SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].IsSupplier = '1';
   SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Manufacturing = '0';
   SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].OperationMode =
      InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.PSCAMA.AUDIT_ACTN;

   --Address segment
   SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Address1 =
      InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.ADDRESS1
      || InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.ADDRESS2;

   SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Address2 =
      InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.ADDRESS3
      || InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.ADDRESS4;


   SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.City = InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.CITY;
   SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.State = InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.STATE;
   SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.zipCode = InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.POSTAL;
   SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Country = InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.COUNTRY;
   SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.OperationMode = InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.PSCAMA.AUDIT_ACTN;

   --Contact Segment
   declare m INTEGER;
   DECLARE MCNT INTEGER;
   SET MCNT = CARDINALITY(InputRoot.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG[])
   SET m = 1;

   WHILE (m <= MCNT) DO

      SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].Name =
         InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG[m].CONTACT_NAME;
      SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].Title =
         InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG[m].TITLE;
      SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].EmailAddress =
         InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG[m].EMAILID;

      declare PhoneType CHARACTER;
      DECLARE N INTEGER;
      DECLARE Phone_No CHARACTER;
      DECLARE NCNT INTEGER;
      SET NCNT = CARDINALITY(InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG.HNA_CTPHN_SEG[]);

      SET N = 1;

      WHILE (N <= NCNT) DO

         SET PhoneType =InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG[m].HNA_CTPHN_SEG[N].PHONE_TYPE;
         set Phone_No=InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG[m].HNA_CTPHN_SEG[N].COUNTRY_CODE
            || InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG[m].HNA_CTPHN_SEG[N].PHONE
            || InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG[m].HNA_CTPHN_SEG[N].EXTENSION;

         IF PhoneType = 'BUSN' then
            SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].TelNumber = Phone_No;
         end if;
         if PhoneType = 'FAX' then
            SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].FaxNumber = Phone_No;
         end if;
         if PhoneType = 'CELL' then
            SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].CellPhone = Phone_No;
         end if;
         if PhoneType = 'PAGER1' then
            SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].PagerNumber = Phone_No;
         else
            if PhoneType = 'PAGER2' then
               SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].PagerNumber = Phone_No;
            end if;
         end if;
         set N=N+1;
      end while;
      SET OutputRoot.XML.SupplierFeed.SupplierInfo[I].Address.Contact[m].EmailAddress =
      InputRoot.XML.HNA_VENDOR.MsgData.Transaction.HNA_VENDOR_SEG.HNA_LOCDESC_SEG[I].HNA_VNDRLOC_SEG.HNA_VNDADDR_SEG.HNA_VNDCNT_SEG[m].PSCAMA_AUDIT_ACTN;
      SET m = m+1;
   END WHILE;
   SET I = I+1;
END WHILE;

_________________
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
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » MESSAGE IS GETTING INTO O/P QUEUE AS IT IS, WHY?
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.