skip to main content
Using DataDirect Test : DataDirect Test Tutorial : Updatable Result Sets : Inserting a Row
 

Inserting a Row

1. From the Connection window menu, select Connection / Create JDBC 4.0 Statement.
2. In the resultSetType field, select TYPE_SCROLL_SENSITIVE. In the resultSetConcurrency field, select CONCUR_UPDATABLE.
Click Submit; then, click Close.
3. Select Statement / Execute Stmt Query.
4. Specify the Select statement that you want to execute.
Click Submit; then, click Close.
5. Select Results / Inspect Results. The Inspect Result Set window is displayed.
6. Click Move to insert row; Current Row is now Insert row.
7. Change Data Type to int. In Set Cell Value, enter 20. Click Set Cell.
8. Select the second row in the top pane. Change the Data Type to String. In Set Cell Value, enter RESEARCH. Click Set Cell.
9. Select the third row in the top pane. In Set Cell Value, enter DALLAS. Click Set Cell.
10. Click Insert Row.
11. To verify the result, return to the Connection menu and select Connection / Load And Go. The Get Load and Go SQL window appears.
12. Specify the statement that you want to execute.
Click Submit; then, click Close.
13. The Connection window shows the row has been added.
Note that the ID will be 3 for the row just inserted, because it is an auto increment column.