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 » Question on XML input to an MQSI messageflow

Post new topic  Reply to topic
 Question on XML input to an MQSI messageflow « View previous topic :: View next topic » 
Author Message
kwelch
PostPosted: Thu Oct 11, 2001 1:26 pm    Post subject: Reply with quote

Master

Joined: 16 May 2001
Posts: 255

Hi all,

I am reading XML data into my MQSI flow and ran across a situation I do not know how to handle. In the data I am receiving a tag that looks like the following . I have been told that this is called an XML shortcut and is used when a required tag has no data. My MQSI process bombed telling me it was getting an unexpected Null. So, I added a check for:
IF name IS NOT NULL THEN
set the OutputRoot.name = InputBody.name;
ELSE
set OutputRoot.name = ' ';(since this is going to a legacy cobol system it needs to have something there.)
END IF;

This produced the same result, unexpected NULL. Does anyone know what code I need to put in place to handle this situation?

Thanks.

Karen
The Hartford Ins. Co.
Back to top
View user's profile Send private message Send e-mail
kwelch
PostPosted: Thu Oct 11, 2001 1:30 pm    Post subject: Reply with quote

Master

Joined: 16 May 2001
Posts: 255

oops! I did not disable the HTML. The tag name from my previous message should display as follows: <name/>

Karen
Back to top
View user's profile Send private message Send e-mail
Tibor
PostPosted: Thu Oct 11, 2001 1:42 pm    Post subject: Reply with quote

Grand Master

Joined: 20 May 2001
Posts: 1033
Location: Hungary

Quote:

On 2001-10-11 14:26, kwelch wrote:
IF name IS NOT NULL THEN
set the OutputRoot.name = InputBody.name;
ELSE
set OutputRoot.name = ' ';(since this is going to a legacy cobol system it needs to have something there.)
END IF;

This produced the same result, unexpected NULL.



Karen,

Inputbody is InputRoot.*[LAST] ordinarly InputRoot.[parser].
OutputRoot.name is wrong because where is the parser?

Look a similar code snippet from ESQL reference book:

If InputBody.Wrong.Field IS NOT NULL THEN
SET OutputRoot.XML.Wrong.Field =InputBody.Wrong.Field;
ELSE
SET OutputRoot.XML.Wrong.Field ='';
END IF;


Simpler:

SET OutputRoot.XML.Wrong.Field = coalesce(InputBody.Wrong.Field,'');


Tibor
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 » Question on XML input to an MQSI messageflow
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.