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 » [Solved] Output message of 0 bytes when using Reference

Post new topic  Reply to topic
 [Solved] Output message of 0 bytes when using Reference « View previous topic :: View next topic » 
Author Message
Wim
PostPosted: Wed Oct 25, 2006 5:51 am    Post subject: [Solved] Output message of 0 bytes when using Reference Reply with quote

Newbie

Joined: 25 Oct 2006
Posts: 9
Location: BE, EU

Hi,

I use WMB6.0 and made a very simple flow:
MQInput - Compute - MQOutput
The MQInput Message Domain is XML

The input message is:
<Message>
<Number>1</Number>
</Message>

This is in the Main():
...
CALL CopyMessageHeaders();
DECLARE rOutput REFERENCE TO OutputRoot;
SET rOutput.XML.Test.Nbr = '3';
...

In Debug, I can see the OutputRoot.XML.Test.Nbr element with a value of 3, but the output message is 0 bytes.

When I code this instead:

...
CALL CopyMessageHeaders();
SET OutputRoot.XML.Test.Nbr = '3';
...

the output message gets written correctly.

What's wrong with using a Reference?

Thanks,
-=Wim=-


Last edited by Wim on Thu Oct 26, 2006 5:37 am; edited 1 time in total
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Wed Oct 25, 2006 6:17 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Don't use the XML domain.

Use XMLNSC in version 6.

Really.

But it's got nothing to do with your problem.

You need to create OutputRoot.XMLNSC with the XMLNSC domain. This is done when you do a SET on the actual OutputRoot object, but not when you do the SET on a reference to that object.

So either do a simple SET OutputRoot.XMLNSC.Test.Nbr = '3' first, and then use your reference, or do a
Code:
create field OutputRoot.XMLNSC Domain 'XMLNSC';

_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
Wim
PostPosted: Wed Oct 25, 2006 6:45 am    Post subject: Reply with quote

Newbie

Joined: 25 Oct 2006
Posts: 9
Location: BE, EU

Hi Jeff,

Thanks for your prompt reply.

I tried your suggestion
create field OutputRoot.XMLNSC Domain 'XMLNSC';

When I save the code, I get this error:
Syntax error. Valid options include: ; AS FROM IDENTITY NAME NAMESPACE PARSE REPEAT TYPE VALUE

-=Wim=-
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Wed Oct 25, 2006 6:47 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Well, I didn't say I'd tested that code.

Maybe a simple search will help you.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
madi
PostPosted: Wed Oct 25, 2006 7:58 am    Post subject: Reply with quote

Chevalier

Joined: 17 Jan 2006
Posts: 475

just go to help and look up the create field statement!!!!

--madi
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Wed Oct 25, 2006 1:41 pm    Post subject: Reply with quote

Grand High Poobah

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

or try
Code:
create Lastchild of OutputRoot domain 'XMLNSC' name 'XMLNSC'.

_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » [Solved] Output message of 0 bytes when using 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.