Stored procedures are defined at the verb level. Each stored procedure definition consists of the following elements: StoredProcedureType, StoredProcedureName, ResultSet, and Parameters.
StoredProcedureName is the name of the stored procedure that is associated with the appropriate StoredProcedureType. It is enabled for use with bidirectional languages.
ResultSet determines if the stored procedure returns a result or not (true|false). If the result set is returned, an N-cardinality child for the current business object is created using the values returned in the result set rows.
Parameters can be a combination of input only (IP), output only (OP), and input and output (IO). In the case of Oracle stored procedures, a result set can be returned only as an output parameter. In that case, one of the values in the list of parameters is result set (RS). Parameters are enabled for use with bidirectional languages.
<jdbcasi:JDBCBusinessObjectTypeMetadata xmlns:jdbcasi="http://www.ibm.com/xmlns/prod/websphere/j2ca/jdbc/metadata"> <jdbcasi:TableName>customer</jdbcasi:TableName><jdbcasi:Operation> <jdbcasi:Name>Retrieve</jdbcasi:Name> <jdbcasi:StoredProcedures> <jdbcasi:StoredProcedureType>RetrieveSP</jdbcasi:StoredProcedureType> <jdbcasi:StoredProcedureName>retrieve_cust</jdbcasi:StoredProcedureName> <jdbcasi:ResultSet>false</jdbcasi:ResultSet> <jdbcasi:Parameters> <jdbcasi:Type>IP</jdbcasi:Type> <jdbcasi:PropertyName>primaryKey</jdbcasi:PropertyName> </jdbcasi:Parameters> <jdbcasi:Parameters> <jdbcasi:Type>OP</jdbcasi:Type> <jdbcasi:PropertyName>custCode</jdbcasi:PropertyName> </jdbcasi:Parameters> <jdbcasi:Parameters> <jdbcasi:Type>OP</jdbcasi:Type> <jdbcasi:PropertyName>firstName</jdbcasi:PropertyName> </jdbcasi:Parameters> <jdbcasi:Parameters> <jdbcasi:Type>OP</jdbcasi:Type> <jdbcasi:PropertyName>lastName</jdbcasi:PropertyName> </jdbcasi:Parameters> </jdbcasi:StoredProcedures> <jdbcasi:StoredProcedures> <jdbcasi:StoredProcedureType>AfterRetrieveSP</jdbcasi:StoredProcedureType> <jdbcasi:StoredProcedureName>retrieve_cust</jdbcasi:StoredProcedureName> <jdbcasi:ResultSet>false</jdbcasi:ResultSet> <jdbcasi:Parameters> <jdbcasi:Type>IP</jdbcasi:Type> <jdbcasi:PropertyName>primaryKey</jdbcasi:PropertyName> </jdbcasi:Parameters> <jdbcasi:Parameters> <jdbcasi:Type>OP</jdbcasi:Type> <jdbcasi:PropertyName>custCode</jdbcasi:PropertyName> </jdbcasi:Parameters> <jdbcasi:Parameters> <jdbcasi:Type>OP</jdbcasi:Type> <jdbcasi:PropertyName>firstName</jdbcasi:PropertyName> </jdbcasi:Parameters> <jdbcasi:Parameters> <jdbcasi:Type>OP</jdbcasi:Type> <jdbcasi:PropertyName>lastName</jdbcasi:PropertyName> </jdbcasi:Parameters> </jdbcasi:StoredProcedures> </jdbcasi:Operation> </jdbcasi:JDBCBusinessObjectTypeMetadata>
The property ReturnDummyBOForSP returns output parameters even when the result set is true but empty. In the case of RetrieveSP, a result set is returned. If the result set is empty, no business objects are created and there is no way to retrieve the output parameters returned by the procedure call. If ReturnDummyBOForSP is true, a dummy business object with values from the output and input/output parameters populated in the corresponding attributes is returned. The default value for this property is false.
Last updated: Thu Mar 23 13:24:31 2006
(c) Copyright IBM Corporation 2005.
This information center is powered by Eclipse technology (http://www.eclipse.org)