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 » Calling ESQL function in mapping

Post new topic  Reply to topic
 Calling ESQL function in mapping « View previous topic :: View next topic » 
Author Message
mansoorafzal
PostPosted: Sun Mar 07, 2010 9:38 pm    Post subject: Calling ESQL function in mapping Reply with quote

Novice

Joined: 19 May 2009
Posts: 14

Hi All,

I have created this function in .esql file.
The function is called in mapping where AccountNumber is being set with the returned value of the function. The data type of the AccountNumber is string.

CREATE FUNCTION GetAccount(stan CHARACTER) RETURNS CHARACTER
BEGIN
DECLARE varAccount CHARACTER;
DECLARE varRow ROW;

SET varRow.FOO[] = SELECT ITEM V.FROM_ACC FROM
--Database.{DATABASE_SOURCE}.{DATABASE_SCHEMA}.CVWPHX_TRAN_RECORD AS V
Database.ORCL.INTFCJ.CVWPHX_TRAN_RECORD AS V
WHERE V.STAN = stan;

SET varAccount = CAST(varRow.[1] AS CHARACTER);

RETURN varAccount;
END;

.bar file is build successfully but isn't deployed.

Any ideas?
Thanks in advance.
Thanks in advance.
Back to top
View user's profile Send private message
mansoorafzal
PostPosted: Sun Mar 07, 2010 10:30 pm    Post subject: Reply with quote

Novice

Joined: 19 May 2009
Posts: 14

okay...
the code deployed and following is the mapping trace from the failure terminal of mapping node:

(0x03000000):Text = 'Must give a dataSourceName attribute' (CHARACTER)
(0x01000000):Insert = (
(0x03000000):Type = 5 (INTEGER)
(0x03000000):Text = '.GetAccount' (CHARACTER)
)
(0x01000000):Insert = (
(0x03000000):Type = 5 (INTEGER)
(0x03000000):Text = '6.33' (CHARACTER)
)
)

Any ideas ?
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Mon Mar 08, 2010 8:07 am    Post subject: Reply with quote

Grand High Poobah

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

Code:
(0x03000000):Text = 'Must give a dataSourceName attribute' (CHARACTER)

Seems pretty clear to me...
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
vanshul
PostPosted: Wed Mar 10, 2010 1:38 am    Post subject: Reply with quote

Novice

Joined: 06 Jun 2008
Posts: 13

DATABASE_SOURCE -- there will be some name of this Data source name

Add that on compute node property in case its missed....
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 » Calling ESQL function in mapping
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.