Welcome to our blog! Today, we’re excited to introduce a new enhancement to the Create INSERT Script feature in Hora. This update gives you more flexibility and control when generating INSERT statements for your tables.
Until now, INSERT scripts were generated by scripting the data content of a table. You could adjust the output by:
Filtering rows with WHERE
conditions to limit the data being scripted.
Hiding columns in the data grid to exclude their content from the export.
While these options worked well, some scenarios still required additional flexibility.
Explore possibilities of KeepTool.
Many customers asked for the ability to:
Populate primary key columns with values from a sequence instead of the original data.
Insert timestamps or dates using the current system date instead of existing values.
Define other constants or function calls directly in the INSERT script, rather than exporting table values.
This level of customization was not possible—until now.
In KeepTool 16.2.3, we’ve extended the INSERT Script dialog with a new “Fixed values” section.
This section provides a grid with two columns:
Column Name – Select the target column (e.g., DEPARTMENT_ID
).
Fixed Value – Enter a value manually or choose one from a dropdown list.
You can use any constant or expression valid in an INSERT statement. Hora suggests common options such as:
CURRENT_TIMESTAMP
Date constants
Sequences from your Oracle schema
Suppose you want to generate new primary key values instead of reusing exported ones.
Select DEPARTMENT_ID
.
Set the value to DEPARTMENTS_SEQ.NEXTVAL
.
Hora will then use the sequence to populate the primary key column automatically.
The generated INSERT script now assigns primary key values from a sequence rather than reusing existing table data.
This makes it much easier to prepare scripts for populating fresh datasets, testing environments, or initializing new tables.
With the new Fixed values feature, you can:
Generate INSERT scripts with dynamic or constant values.
Use sequences, functions, and expressions to replace original data.
Simplify the process of preparing reusable and flexible INSERT scripts.
This enhancement provides greater control and streamlines your workflow when working with INSERT statements in Hora.
KeepTool’s Oracle database tools have been developed for database application developers as well as database administrators and application support. Based on the feedback and requests of our customers, we have been continuously improving our tools for more than 20 years and strive to improve with each new release.