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 IndexWebSphere Message Broker (ACE) SupportESQL NULL handling for scalar values?

Post new topicReply to topic
ESQL NULL handling for scalar values? View previous topic :: View next topic
Author Message
pcoffey
PostPosted: Tue Oct 24, 2006 5:59 am Post subject: ESQL NULL handling for scalar values? Reply with quote

Apprentice

Joined: 03 Feb 2006
Posts: 33

Hi,

I have a an ESQL CHAR variable which I use to retrieve a value from a database table column - using THE (SELECT T.COL FROM Database.TABLE AS T)

I want to test the returned value for NULL and was using

IF nextCode = NULL THEN...

However, this fails as, according to the ESQL help, “ESQL provides a full set of comparison operators (predicates). Each compares two scalar values and returns a Boolean. If either operand is null the result is null. Otherwise the result is true if the condition is satisfied and false if it is not.”

As such, I get the following in a user trace:

Evaluating expression ''nextCode = NULL'' at ('ie.xxx.ifg.shared.xref.AssignCode', '23.20'). This resolved to ''NULL = NULL''. The result was ''NULL''.

Surely there is some way I can to test the scalar value for NULL? Has anyone any suggestions?

Thanks,
Pauline
Back to top
View user's profile Send private message
pcoffey
PostPosted: Tue Oct 24, 2006 6:13 am Post subject: Reply with quote

Apprentice

Joined: 03 Feb 2006
Posts: 33

Finally found the IS test buried in the ESQL reference.
Back to top
View user's profile Send private message
Display posts from previous:
Post new topicReply to topic Page 1 of 1

MQSeries.net Forum IndexWebSphere Message Broker (ACE) SupportESQL NULL handling for scalar values?
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.