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 » How to use JOIN when access external DB2 from WMQIv2.1

Post new topic  Reply to topic
 How to use JOIN when access external DB2 from WMQIv2.1 « View previous topic :: View next topic » 
Author Message
fnl
PostPosted: Wed May 29, 2002 1:06 pm    Post subject: How to use JOIN when access external DB2 from WMQIv2.1 Reply with quote

Newbie

Joined: 20 Jan 2002
Posts: 6
Location: Waterloo, ON.

Hi,

We use WMQIv2.1.

The following SQL expression works ok on OS/390, but whe I copy it to a compute node in the flow, I got a syntax error. An red cursor appears just befor the JOIN.

SET OutputRoot.XML.BrkList[] =
(SELECT A.BRK_GRP_ID
,A.CO_CD
,A.BRK_NUM
FROM Database.DB2T9.TEB_BRK_GRP_REL AS A
JOIN Database.DB2T9.TEB_BRK_USER AS B
ON A.BRK_GRP_ID = B.BRK_GRP_ID
WHERE B.BRK_USER_ID = 'EB9');


I was wornding if ESQL allows the JOIN clause to join tables when access external DB2? I didn't find it in the ESQL Reference document.

If anybody knows how to do this, please help.

Thank you in advance!

Fanny.
Back to top
View user's profile Send private message
kirani
PostPosted: Wed May 29, 2002 1:39 pm    Post subject: Reply with quote

Jedi Knight

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

Fanny,

WMQI does not support JOIN clause directly. However, you can use it in a PASSTHRU statement. You can join two tables using SELECT statement as follows,

SET OutputRoot.XML.BrkList[] = (SELECT A.BRK_GRP_ID, A.CO_CD, A.BRK_NUM FROM Database.DB2T9.TEB_BRK_GRP_REL AS A,
Database.DB2T9.TEB_BRK_USER AS B
WHERE
A.BRK_GRP_ID = B.BRK_GRP_ID AND
B.BRK_USER_ID = 'EB9');
_________________
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 » How to use JOIN when access external DB2 from WMQIv2.1
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.