Template

It describes the feature of Template.

Template is a feature that allows you to save frequently used SQL statements and reuse them when needed. This can truncate repetitive SQL writing tasks and increase work efficiency.

Select [View] menu - [Template] menu or select [Template] menu from the Editor Context Menu to display the Template area on the right side of the application. The top area provides the Template Tree List and add, delete, and edit functions, and the bottom area provides the Preview area where you can preview the contents of the template.

Template

There are the following three types of templates.

SQL Template

  • Saves and reuse common SQL query statements.

  • Saves all types of SQL statements such as SELECT, INSERT, UPDATE, and DELETE.

PSM Template

  • Stores PSM code such as Procedure and Function.

  • Procedures and functions containing complex business logic can be managed as templates.

  • Utilizes the saved template when creating database objects.

User Defined Template

  • Stores custom code snippets that you define.

  • Saves frequently used code patterns or syntax as templates.

  • Shown in the autocomplete list and can be easily inserted when writing code.

Using Template

Double-clicking a Template Tree item will automatically enter the contents of that Template in the currently focused Editor. For User Defined Templates, the Editor displays the Template name in the Auto Complete list, and when you select the Template name.

Auto Complete

Adding Template

Click the button at the top of the Template area to display a modal window to add a Template, or click the Insert Template menu from the Context Menu of the Template at the location to add.

Add Template

The following information can be entered.

Name

The name of the Template. Names cannot be duplicated within the same Type.

Type

The type of the template. You can select SQL, PSM, or User Defined.

Code

The content of the template. It supports keyword autocomplete and basic context menu functions.

Variables

Supports inserting various data values when double-clicking.

Modifying Template

Click the Edit menu in the Context Menu of the Template Tree itemto modify to display a modal window where the user can modify the Template. However, the Template Type cannot be modified.

Edit Template

Deleting Template

Deletes the desired Template by clicking the Delete menu in the context menu of the Template Tree item to modify.

Reset Template

Click the button in the top area to reset the template to its initial state. SQL and PSM Templates will be reverted to the built-in Template list and all User Defined lists will be removed.

Last updated