Encapsulates table operations for direct row handling uploads.
public interface UploadedTableData
All members of UploadedTableData interface, including all inherited members.
Name | Description |
---|---|
Returns a java.sql.ResultSet object representing delete operations uploaded by a MobiLink client. | |
Returns a java.sql.ResultSet object representing insert operations uploaded by a MobiLink client. | |
Gets the metadata for the UploadedTableData instance. | |
Returns the table name for the UploadedTableData instance. | |
Returns a UpdateResultSet object representing update operations uploaded by a MobiLink client. |
You can use an UploadedTableData instance to obtain a table's insert, update, and delete operations for a single upload transaction. Use the getInserts, getUpdates, and getDeletes methods to return standard JDBC java.sql.ResultSet objects.
Consult your Java Software Development Kit documentation for more information about java.sql.ResultSet and java.sql.ResultSetMetaData.
Table metadata can be accessed using the getMetaData method or the result sets returned by getInserts, getUpdates, and getDeletes. The delete result set only includes primary key columns for a table.
For more information about direct row handling, see Direct row handling.
For more information about the handle_UploadData connection event, see handle_UploadData connection event.
The following code gets the deletes uploaded and prints out the first column of each:
void printFirstColOfDeletes( UploadedTableData tab_data ) { ResultSet deletes = tab_data.getDeletes(); while( deletes.next() ) { java.lang.System.out.println( deletes.getString( 1 ) ); } deletes.close(); } |
The following code prints the new and old value of the third column of each update:
void printThirdColOfUpdates( UploadedTableData tab_data ) { ResultSet updates = tab_data.getUpdates(); while( updates.next() ) { updates.setOldRowValues(); java.lang.System.out.println( "old row col: " + updates.getString( 3 ) ); updates.setNewRowValues(); java.lang.System.out.println( "new row col: " + updates.getString( 3 ) ); } updates.close(); } |
getDeletes method
getInserts method
getMetaData method
getName method
getUpdates method
Discuss this page in DocCommentXchange.
|
Copyright © 2012, iAnywhere Solutions, Inc. - SQL Anywhere 12.0.1 |