Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 365650

Summary: Data source explorer fails to display MySQL stored procedure
Product: [Tools] Data Tools Reporter: Ram Venkataswamy <ram.venkataswamy>
Component: Data Source ExplorerAssignee: Pierre Queinnec <pierre.queinnec>
Status: ASSIGNED --- QA Contact:
Severity: normal    
Priority: P3 CC: pierre.queinnec
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows 7   
Whiteboard:

Description Ram Venkataswamy CLA 2011-12-05 13:51:42 EST
Build Identifier: M20110909-1335

Data source explorer fails to display MySQL stored procedure 

Reproducible: Always

Steps to Reproduce:
- Create a DB connection to MySQL database (ex: HR schema)

- Open Scrapbook and create a stored procedure

Sample:

CREATE PROCEDURE SP_SELECT_MYSQL
( IN ID VARCHAR(10), OUT IDENTITY VARCHAR(10), OUT PASSWD VARCHAR(10), OUT NAME VARCHAR(10))
BEGIN
  SELECT EMPLOYEE_ID, EMPLOYEE_NAME
  INTO IDENTITY, PASSWD, NAME
  FROM EMPLOYEES
  WHERE EMPLOYEE_ID = ID;
END

- Executing the SQL succeeds

In Data Source explorer, refresh the schema/stored procedure node. The newly created procedure is not displayed.
Comment 1 Pierre Queinnec CLA 2012-05-18 12:56:56 EDT
Hi Ram, this seems like it's not a bug. Your procedure returns three results, so it's considered as a UDF, not a stored procedure.

So the workaround is to look under 'User-Defined Functions' in the tree, not under 'Stored Procedures'.

Could you confirm it works? Thanks.