You can use an external editor to create or edit a database,
signal, or temporal trigger.
Before you begin
You must have configured an external editor to use for creating
or editing triggers.
About this task
To create or edit a trigger:
Procedure
- From the Netcool/OMNIbus Administrator window,
select the Automation menu button.
- Click Triggers.
The
Triggers pane
opens. This window lists all database, signal, and temporal triggers
that are set up.
Tip: To view only one type of
trigger, click Show Database Triggers Only, Show
Temporal Triggers Only, or Show Signal Triggers Only in
the toolbar.
- To create a trigger, make sure that no row is selected
in the Triggers pane, and then click Edit
in External Editor in the toolbar. (You can deselect a
row by pressing Ctrl and then clicking the row.)
The Select
Trigger Type dialog box opens. Proceed as follows:
- From the Trigger Template list,
select the template for the type of trigger that you want to create.
If you select Database, Signal,
or Temporal, the external editor opens with
standard syntax for that trigger type. If you select <blank>,
the external editor opens with no text shown.
- Complete the syntax for the trigger. If you are using
a template, replace the trigger_name and group_name variables
with real values. Additionally, for a signal trigger, replace the signalName variable
with a real value, and for a database trigger, replace the database_name.table_name variable
with a real value. Add trigger-specific statements, optional clauses,
and variable declarations, as required. Then add the body of the trigger
between the Begin and End keywords. The template includes comments
(preceded by --) for the placement of text.
- Save your entries.
When you save, the
trigger is saved to the ObjectServer. If there are any syntax errors,
you are prompted to reload the contents of the external editor.
- Close the external editor.
- To edit a trigger, select the trigger to edit and then
click Edit in External Editor in the toolbar,
or right-click and select Edit in External Editor from
the pop-up menu.
The external editor opens, with the trigger
syntax displayed. Proceed as follows:
- Edit the trigger syntax and save your changes.
When you save, the trigger is saved to the ObjectServer.
If there are any syntax errors, you are prompted to reload the contents
of the external editor.
- Close the external editor.
Results
Tip: The SQL that you enter in an external editor
is saved to the ObjectServer as a .ed file. You
can check the validity of the syntax in .ed and
other .sql files from the SQL interactive interface
(running in GUI mode).