Map custom entity to output parameter of a stored procedure
Posted: Wed 03 Jun 2009 06:54
Using the entity developer what would be the approach to map an output parameter of type REF CURSOR to a custom class
I proceeded as follow :
The Stored procedure has a definition like :
PROCEDURE BOM_BY_PRODUCT (componentID in NUMBER, p_recordset OUT SYS_REFCURSOR);
- Drag and drop the stored procedure on the design surface of the ED
- This generated a method in the DataSourceModel with input parameter of type decimal and output parameter of type binary.
- I added an entity class Class1 and defined a property for each field as defined in the recordset of the output parameter.
- Then I selected the generated method and via the parameters property I selected the entity Class1 as the return type.
Now the model still does not validate as it says No mapping specified for the following EntitySet/AssociationSet - Class1.
Before using the Entity developer I managed to do this by defining the appropriate mappings manually in the msdl file. Is the entity developer supporting this mapping in a different way ? If not any plans to do so ?
I proceeded as follow :
The Stored procedure has a definition like :
PROCEDURE BOM_BY_PRODUCT (componentID in NUMBER, p_recordset OUT SYS_REFCURSOR);
- Drag and drop the stored procedure on the design surface of the ED
- This generated a method in the DataSourceModel with input parameter of type decimal and output parameter of type binary.
- I added an entity class Class1 and defined a property for each field as defined in the recordset of the output parameter.
- Then I selected the generated method and via the parameters property I selected the entity Class1 as the return type.
Now the model still does not validate as it says No mapping specified for the following EntitySet/AssociationSet - Class1.
Before using the Entity developer I managed to do this by defining the appropriate mappings manually in the msdl file. Is the entity developer supporting this mapping in a different way ? If not any plans to do so ?