Oracle ROWID Support for DML

Formspider 1.9 lets developers use the Oracle ROWID to update and delete rows in the database. This is especially useful if the Datasource Definition has a multi column primary key. In Formspider, only a single column in the datasource definition can be assigned as the primary key. Prior to 1.9 developers had to create a virtual primary key column to be able to issue DML statements from the datasources based on a datasource definition with a multi column primary key. This process was tedious and error prone.

To enable DML operations using the Oracle ROWID simply check the checkbox in the datasource definition dialog in the Formspider IDE as shown in the picture below.

API’s

The API_DATASOURCE package has new API’s so that developers can interact with the datasources using the Oracle ROWID as the unique identifier for a row fetched into the datasource. The list of the new API’s are below. Please see the Formspider API Documentation for more information about these new API’s.

getRowNumberByOraRowID(in_datasourceName_tx varchar2, in_oraRowID_ri rowid) return number;

deleteRowByOraRowID(in_datasourceName_tx varchar2,in_oraRowID_ri rowid);

setCurrentRowByOraRowID(in_datasourceName_tx varchar2,in_oraRowID_ri rowid);

refreshRowByOraRowID(in_datasourceName_tx varchar2, in_oraRowID_ri rowid);

getRowStatusByOraRowID(in_datasourceName_tx varchar2,in_oraRowID_ri rowid) return varchar2;

getOraRowID(in_datasourceName_tx varchar2, in_row_id number:=null) return rowid;

setRowNumberByOraRowID(in_datasourceName_tx varchar2,in_oraRowID_ri rowid,in_rowNumberInPage_nr number, in_page_nr number:=null);

getRowByOraRowID(in_datasourceName_tx varchar2, in_oraRowID_ri rowid) return tt_row;

setColumnValueByOraRowID(in_datasourceDotColumn_tx varchar2, in_value_tx varchar2, in_oraRowID_ri rowid)

setColumnValueByOraRowID(in_datasourceDotColumn_tx varchar2, in_value_nr number, in_oraRowID_ri rowid);

setColumnValueByOraRowID(in_datasourceDotColumn_tx varchar2, in_value_dt date, in_oraRowID_ri rowid);

setColumnValueByOraRowID(in_datasourceDotColumn_tx varchar2, in_value_cl clob, in_oraRowID_ri rowid);

setColumnValueByOraRowID(in_datasourceDotColumn_tx varchar2, in_value_bl blob, in_oraRowID_ri rowid);

getColumnValueTXByOraRowID(in_datasourceDotColumn_tx varchar2, in_oraRowID_ri rowid) return varchar2;

getColumnValueNRByOraRowID(in_datasourceDotColumn_tx varchar2, in_oraRowID_ri rowid) return number;

getColumnValueDTByOraRowID(in_datasourceDotColumn_tx varchar2, in_oraRowID_ri rowid) return date;

getColumnValueCLByOraRowID(in_datasourceDotColumn_tx varchar2, in_oraRowID_ri rowid) return clob;

getColumnValueBLByOraRowID(in_datasourceDotColumn_tx varchar2, in_oraRowID_ri rowid) return blob;

getRowNumberInPageByOraRowID(in_datasourceName_tx varchar2, in_oraRowID_ri rowid) return number;

getRowIDByOraRowID(in_datasourceName_tx varchar2, in_oraRowID_ri rowid) return number;