Interstage Shunsaku Data Manager Application Development Guide - Microsoft(R) Windows(R) 2000/ Microsoft(R) Windows Server(TM) 2003 - - UNIX - |
Contents
Index
![]() ![]() |
Part 1 The Basic for Developing Application | > Chapter 6 Direct Access Function | > 6.6 Updating Data by Direct Access Key |
The updateByKey method is used in the direct update for Java API.
The following figure shows the flow of the direct update for Java API.
ShunConnection con = new ShunConnection(); ShunPreparedKey preUkey = con.prepareUpdateKey("key1"); (1) preUkey.add("20061101,00000001", updateData1); (2) preUkey.add("20061101,00000002", updateData2); (2) preUkey.add("20061101,00000003", updateData3); (2) preUkey.setSearchType(ShunPreparedKey.SHUN_KEY_COMPLETE_MATCH); preUkey.updateByKey(); (3) preUkey.close(); (4) con.close(); |
Specify a direct access key name as parameters of the prepareUpdateKey method to create a ShunPreparedKey object.
Use the Add method to set the direct access key and the to be updated.
Multiple direct access keys and the update data can be set by using the add method.
Specifying multiple direct access keys and the update data with the add method to update multiple XML documents at a time.
Use the updateByKey method to execute the update process.
Use the close method of the ShunPreparedKey object to release the object when it is no longer required.
Refer to F.3.4 Update Data Using Direct Access Key for the sample program of the direct access.
Contents
Index
![]() ![]() |