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

Bug 339905

Summary: EclipseLink needs new query processing to handle optional arguments
Product: z_Archived Reporter: Mike Norman <michael.norman>
Component: EclipselinkAssignee: Nobody - feel free to take it <nobody>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: david.twelves
Version: unspecified   
Target Milestone: ---   
Hardware: All   
OS: All   
Whiteboard:
Bug Depends on:    
Bug Blocks: 339909    
Attachments:
Description Flags
patch none

Description Mike Norman CLA 2011-03-14 11:16:40 EDT
Both BPEL and DBWS need to handle the usecase where a Stored Procedure
(on Oracle) has arguments with defaults specified. Thus when invoking the
Stored Procedure, some arguments need not be provided as they are optional
at runtime.

The current capabilities of Queries that are serialized to Project XML
are such that in order to handle optional arguments, one must create
a query for each of the possible combinations - this unfortunately experiences
a combinatorial explosion at the rate of 2**N.

What is needed is a singular Query artifact that encompasses all the
information about mandatory and optional arguments and adjusts accordingly
at runtime to whatever parameters are available.
Comment 1 James Sutherland CLA 2011-04-13 09:54:46 EDT
Created attachment 193159 [details]
patch
Comment 2 James Sutherland CLA 2011-04-13 10:21:05 EDT
SVN trunk pending commit: Bug#339905 - optional procedure arguments

 

https://bugs.eclipse.org/bugs/show_bug.cgi?id=339905

 

http://wiki.eclipse.org/EclipseLink/DesignDocs/275156

 

Code review: Mike (pending)

 

Changes:

- Added tests for optional arguments and rec cursors to foundation PLSQL test model.

- Added optional to JPA StoredProcedureParameter annotation and xml.

- Added some @Overrides and micro optimizations.

- Changed parameters in calls to List from Vector.

- Added query and call support for specified nullable arguments to trigger reprepare of the query and be omitted from the statement.

- Added JPA annotations and xml for PLSQL procedures and functions.

- Added stored procedure and plsql procedure support for optional arguments.

- Removed some dead code.

- Added PLSQL JPA test model and tests.
Comment 3 James Sutherland CLA 2011-04-20 14:23:58 EDT
fixed
Comment 4 Eclipse Webmaster CLA 2022-06-09 10:24:58 EDT
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink