Using Database Operations

Using Result Sets with stored procedures:

In order to scroll back in a result set returned from a stored procedure, the <OTD>.setScrollTypeToScrollInsensitive() method should be called before any other methods for the OTD.

Example:

Sch_StoredProcedures.setScrollTypeToScrollInsensitive();

Sch_StoredProcedures.getUsp_GetAppointment().setPatientID( PatientID );

Sch_StoredProcedures.getUsp_GetAppointment().setAppointmentDate( ApointmentDateTime );

Sch_StoredProcedures.getUsp_GetAppointment().execute();

Sch_StoredProcedures.getUsp_GetAppointment().enableResultSetsOnly();

If the <OTD>.setScrollTypeToScrollInsensitive() method is not called, then any attempt to move back in the resultset will fail.

Example:

Executing ’Sch_StoredProcedures.getUsp_GetAppointment().get$usp_GetAppointmentResultSets0().first();’ will fail with the exception: ’Unsupported method: ResultSet.first’.