Show TOC Start of Content Area

Background documentation Handling the Output  Locate the document in its SAP Library structure

For a Function

IInteraction.executereturns MappedRecord as output.

Using MappedRecord can retrieve output parameter values by parameter name: MappedRecord.get(paramname), which returns an object. There are four possibilities of output handling:

...

       1.      If the parameter type is a primitive, you get an object, such as String, Integer, Float, etc.

       2.      If the parameter type is tabular, IRecordset is returned. (IRecordset is parallel to the standard java.sql.resultset.)

Note

Inside IRecordset, each column may also be of one of these four types.

       3.      If the parameter type is array, then it returns an array of objects of one of these four types.

       4.      If the output is a set of objects where each of them may be one of these four types, IRecordset is returned.

Note

The following explanation applies to case 2 and 4:

IRecord and IRecordset are both extensions of IAbstractRecord (which is also similar to java.sql.resultset). IAbstractRecord exposes get methods to a specific type of object, such as getInteger; it also expose a general return pipe, such as getObject. All get methods can be invoked by column name or index.

IAbstractRecord can also expose the metadata of each column by invoking retrieveMetaData. This may be useful before invoking other get methods.

IRecordset can use a set of methods, such as next() to manipulate cursor position. This is also similar to java.sql.resultset.

For a Query

INativeQuery returns an object, the type of which depends on the EIS. For example, an RDBMS using the JDBC connector returns java.sql.resultset.

execute(IOperation operation)returns an integer indicating a number of rows. Iterate using IExection methods to retrieve the entire record set.

See the Javadoc for the portal and portal runtime APIs, located on the SAP Developer Network (SDN) at www.sdn.sap.com/irj/sdn/javadocs. The packages related to the connector framework start with com.sapportals.connector*.

 

 

End of Content Area