|  | 
 
  
    | RSS Feed - WebSphere MQ Support | RSS Feed - Message Broker Support |  
 
  
	|    |  |  
  
	| Calling a function from ESQL | « View previous topic :: View next topic » |  
  	| 
		
		
		  | Author | Message |  
		  | basva | 
			  
				|  Posted: Wed Nov 27, 2002 12:46 pm    Post subject: Calling a function from ESQL |   |  |  
		  | Apprentice
 
 
 Joined: 27 Nov 2002Posts: 39
 
 
 | 
			  
				| Hi 
 I am calling an Oracle function from ESQL, but getting an error saying "Invalid Cursor State". Can someone correct me what I am doing wrong. Here is my ESQL
 
 Set OutputRoot.XML.Out.Results[] = PASSTHRU('call f(?,?)', p1, p2);
 
 
 Thanks
 Satish
 |  |  
		  | Back to top |  |  
		  |  |  
		  | kirani | 
			  
				|  Posted: Wed Nov 27, 2002 9:26 pm    Post subject: |   |  |  
		  | Jedi Knight
 
 
 Joined: 05 Sep 2001Posts: 3779
 Location: Torrance, CA, USA
 
 | 
			  
				| Satish, You could call only stored procedure using CALL ESQL statement. Try writing a stored procedure, which calls your stored function.
 _________________
 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 |  |  
		  |  |  
		  | Ian | 
			  
				|  Posted: Thu Nov 28, 2002 4:10 am    Post subject: |   |  |  
		  | Disciple
 
 
 Joined: 22 Nov 2002Posts: 152
 Location: London, UK
 
 | 
			  
				| Hi Satish, 
 You need to be more clear about what your environment is (MQSI or WMQI version).
 
 However, we do know the following :
 
 1. MQSIv2.0.* and WMQIv2.1 support calling stored procedures with INPUT parameters ONLY but do not support OUT or INOUT parameters and is implemented via the PASSTHRU function.
 
 2. WMQIv2.1 CSD02 includes support for calling stored procedures with IN, OUT and INOUT parameters and is implemented via the CREATE PROCEDURE command :
 
 
   
	| Code: |  
	| CREATE PROCEDURE spName (...) EXTERNAL NAME spDBName; |  
 From the information you have supplied I would draw the conclusion that what you are attempting is not supported based on the following :
 
 
 
   
	| Quote: |  
	| I am calling an Oracle function |  
 1. A function returns a value and MQSIv2.0.* does not support returned values and therefore can not support this.
 
 2. WMQIv2.1 CSD02 explicitly states that it includes support for calling stored procedures with IN, OUT and INOUT parameters and is implemented via the CREATE PROCEDURE command. This also implicitly implies that is does not support calling stored functions.
 _________________
 Regards, Ian
 |  |  
		  | Back to top |  |  
		  |  |  
		  | Yanghui | 
			  
				|  Posted: Tue Sep 02, 2003 1:53 am    Post subject: |   |  |  
		  | Disciple
 
 
 Joined: 08 May 2002Posts: 151
 Location: Dublin, Ireland
 
 | 
			  
				| Hi, there, 
 Is this still the case, I mean there is no way to call Oracle function in ESQL? Thanks.
 
 Regards
 
 -Yanghui
 |  |  
		  | Back to top |  |  
		  |  |  
		  |  |  |  
  
	|    |  | Page 1 of 1 |  
 
 
  
  	| 
		
		  | 
 
 | 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
 
 |  |  |  |