Returns a java.sql.ResultSet object representing insert operations uploaded by a MobiLink client.
java.sql.ResultSet UploadedTableData.getInserts()
A java.sql.ResultSet object representing insert operations uploaded by a MobiLink client.
Each Insert is represented by one row in the result set.
For more information about direct row handling, see Direct row handling.
Assume your remote client contains a table named remoteOrders. The following example uses the DownloadTableData.getInserts method to obtain a result set of inserted rows. The code obtains the order amount for each row in the current upload transaction.
import ianywhere.ml.script.*; import java.sql.*; // The method used for the handle_UploadData event public void HandleUpload(UploadData ut) throws SQLException, IOException { // Get an UploadedTableData instance representing the remoteOrders table. UploadedTableData remoteOrdersTable = ut.getUploadedTableByName("remoteOrders"); // Get inserts uploaded by the MobiLink client. java.sql.ResultSet rs = remoteOrdersTable.getInserts(); while (rs.next()) { // get the uploaded order_amount double order_amount = rs.getDouble("order_amount"); // ... } rs.close(); } |
![]() |
Discuss this page in DocCommentXchange.
|
Copyright © 2012, iAnywhere Solutions, Inc. - SQL Anywhere 12.0.1 |