ConnectorLib Java 23.4

# Insert Records

After you have created a datastore table, you can add records to it:

           DatastoreRecord newRecord = new DatastoreRecord();
           newRecord.setString("Reference", "C:\\data\\file1.txt");
           newRecord.setString("LastModified", "2013/07/30 14:36:00");

           datastore.recordInsert("Documents", newRecord);

This example creates a record, sets values for each column, and inserts the record into the table created in Create Tables. You can set column values using the `setString`, `setLong`, and `setBoolean` methods on the record.

Although you can set any fields you like in the Record, an exception is thrown from the `recordInsert` method if you try to set fields that are not in the table.

Copyright 2022 Open Text
Version 23.4 | Last updated September 2023

Send documentation feedback

Close

Send documentation feedback

To send feedback using your default email client, open an email window.

Otherwise, send your feedback and the information below to swpdl.idoldocsfeedback@microfocus.com.

We appreciate your feedback!

Product: IDOL ConnectorLib Java 23.4

Topic Title: Insert Records