|   | 
	 
  
    | 
RSS Feed - WebSphere MQ Support
 | 
RSS Feed - Message Broker Support
 |   
 
  
	     | 
	 | 
   
 
  
	|  ESQL Calling Oracle 11g Stored Procedure error | 
	« View previous topic :: View next topic »  | 
   
  
  	
	  
		
		
		  | Author | 
		  Message
		 |  
		
		  | mdmader | 
		  
		    
			  
				 Posted: Wed Oct 22, 2008 12:15 pm    Post subject: ESQL Calling Oracle 11g Stored Procedure error | 
				     | 
			   
			 
		   | 
		 
		
		   Newbie
 
 Joined: 17 Apr 2008 Posts: 7
  
  | 
		  
		    
			  
				I've run into a small problem trying to call an Oracle 11g Stored Procedure from ESQL.  
 
 
This procedure is a  simple security verification for an account and service request.  The ESQL triggers the error [DataDirect][ODBC Oracle driver]Optional feature not implemented. when it calls the stored procedure.
 
  
 
 
Actual Error:
 
DatabaseException
 
	File:CHARACTER:F:\build\S610_P\src\DataFlowEngine\ImbOdbc.cpp
 
	Line:INTEGER:359
 
	Function:CHARACTER:ImbOdbcHandle::checkRcInner
 
	Type:CHARACTER:
 
	Name:CHARACTER:
 
	Label:CHARACTER:
 
	Catalog:CHARACTER:BIPv610
 
	Severity:INTEGER:3
 
	Number:INTEGER:2322
 
	Text:CHARACTER:Child SQL exception
 
	Insert
 
			Type:INTEGER:5
 
			Text:CHARACTER:HYC00
 
	Insert
 
			Type:INTEGER:2
 
			Text:CHARACTER:0
 
	Insert
 
			Type:INTEGER:5
 
			Text:CHARACTER:[DataDirect][ODBC Oracle driver]Optional feature not implemented.
 
 
I've searched around on exception but I have not anything that seem relevant.  Searched on the Description and the HYC00 code.  The ODBC Driver I'm using is "MQSeries DataDirect Techonlogies 5.2 32-Bit Oracle Version 5.20.00.67.  Message Broker Version 6.1.0.1, Oracle 9i client 9.2.0.4.0 and Oracle Database 11g Enterprise Edition Release 11.1.0.6.0 - 64bit.
 
 
Every time I try to enable ODBC tracing on my machine and restart Broker, the message flow stays in a stopped state and will not run.  If I remove ODBC trace, the flow will again run.  Again, if anyone had this problem, please enlighten me. 
 
 
Has anyone encountered this and know what the error is referring to and if they know what a solution may be.  
 
 
Any help/pointers/ideas would be appreciated.
 
 
ESQL:
 
CREATE COMPUTE MODULE VerifyRequest
 
	CREATE FUNCTION Main() RETURNS BOOLEAN
 
	BEGIN
 
		SET OutputRoot             = InputRoot;
 
		SET OutputLocalEnvironment = InputLocalEnvironment;
 
		
 
		DECLARE serviceName CHAR;
 
		DECLARE subscriberName CHAR;
 
		DECLARE validRequest CHAR;
 
		DECLARE valid BOOLEAN;
 
		
 
		SET serviceName = InputRoot.MRM.V0_5_SERVICE_NAME;
 
		SET subscriberName = InputRoot.MRM.V0_5_SUBSCRIBERNAME;
 
		
 
		call verify(serviceName, subscriberName, valid); 
 
		
 
		IF (valid <> TRUE) THEN
 
			-- ERROR, Not Valid
 
			SET Environment.Variables.EH.KeyData     = 'Verification Exception';
 
			SET Environment.Variables.EH.messageText = 'Invalid Request.';
 
			THROW EXCEPTION;
 
		END IF;
 
		
 
		RETURN TRUE;
 
	END;
 
	
 
	CREATE PROCEDURE verify(IN p_ServiceName CHAR, IN p_SubscriberName CHAR, INOUT p_Valid BOOLEAN) LANGUAGE DATABASE EXTERNAL NAME "EDSAPP_MGR.PR_EDS_SERVICE.pr_Validate_Service_Call"; 
 
END MODULE;
 
 
Procedure:
 
PROCEDURE pr_Validate_Service_Call(p_ServiceName        IN     VARCHAR2,
 
                                   p_SubscriberName      IN     VARCHAR2, 
 
                                   p_Valid               IN OUT BOOLEAN)
 
AS
 
BEGIN
 
   v_service_found := 0;
 
   SELECT 1
 
   INTO v_service_found
 
   FROM eds_subscription
 
   WHERE svc_subscriber_name = p_subscribername
 
   AND   eds_service_name    = p_servicename;
 
  
 
   if v_service_found = 1 then
 
      p_Valid := TRUE;
 
   else
 
      p_Valid := FALSE;
 
   end if;
 
   
 
   EXCEPTION
 
      WHEN NO_DATA_FOUND THEN
 
         p_Valid := FALSE;
 
 	    WHEN OTHERS THEN
 
         RAISE;
 
END pr_Validate_Service_Call; | 
			   
			 
		   | 
		 
		
		  | Back to top | 
		  
		  	
		   | 
		 
		
		    | 
		 
		
		  | mdmader | 
		  
		    
			  
				 Posted: Thu Oct 23, 2008 8:21 am    Post subject:  | 
				     | 
			   
			 
		   | 
		 
		
		   Newbie
 
 Joined: 17 Apr 2008 Posts: 7
  
  | 
		  
		    
		   | 
		 
		
		  | Back to top | 
		  
		  	
		   | 
		 
		
		    | 
		 
		
		  | balu2608 | 
		  
		    
			  
				 Posted: Sun Dec 02, 2012 9:59 pm    Post subject: Call Procedure Optional field Not Implemented | 
				     | 
			   
			 
		   | 
		 
		
		    Apprentice
 
 Joined: 18 May 2012 Posts: 39
  
  | 
		  
		    
			  
				Hi ,
 
 
Try to add NChar in the odbc.ini file for the data base which you ar loging that will solve ur prob.
 
 
 
enable NChar | 
			   
			 
		   | 
		 
		
		  | Back to top | 
		  
		  	
		   | 
		 
		
		    | 
		 
		
		  | smdavies99 | 
		  
		    
			  
				 Posted: Sun Dec 02, 2012 10:34 pm    Post subject:  | 
				     | 
			   
			 
		   | 
		 
		
		    Jedi Council
 
 Joined: 10 Feb 2003 Posts: 6076 Location: Somewhere over the Rainbow this side of Never-never land. 
  | 
		  
		    
			  
				Why did you post an answer to a four year old thread? This same question has been answered many times since 2008, even as recently as last month.
 
 
IMHO, this is not good forum etiquette. _________________ WMQ User since 1999
 
MQSI/WBI/WMB/'Thingy' User since 2002
 
Linux user since 1995
 
 
 
Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions. | 
			   
			 
		   | 
		 
		
		  | Back to top | 
		  
		  	
		   | 
		 
		
		    | 
		 
		
		  | kash3338 | 
		  
		    
			  
				 Posted: Sun Dec 02, 2012 10:37 pm    Post subject:  | 
				     | 
			   
			 
		   | 
		 
		
		   Shaman
 
 Joined: 08 Feb 2009 Posts: 709 Location: Chennai, India 
  | 
		  
		    
			  
				
   
	| mdmader wrote: | 
   
  
	it appears that BOOLEAN is not supported in ESQL.  
 
 | 
   
 
 
 
The documentation also clearly says this point.
 
http://publib.boulder.ibm.com/infocenter/wmbhelp/v6r1m0/index.jsp
 
 
   
	| mdmader wrote: | 
   
  
	| We modified the proc to return a VARCHAR to make it work.  Still, if anyone has any better suggestions, please let me know. | 
   
 
 
 
The FLOAT datatype should be used for NUMBER's in ORACLE. The same link helps you,
 
 
   
	| Quote: | 
   
  
	| 1.If an Oracle database column with NUMBER data type is defined with an explicit precision (P) and scale (S), it is cast to an ESQL DECIMAL value; otherwise it is cast to a FLOAT. | 
   
 
 | 
			   
			 
		   | 
		 
		
		  | 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
  | 
  		 
	   
	 | 
   
 
  	 | 
	  |