Sunteți pe pagina 1din 35

Oracle Alerts

Mona Lisa Sahu

TCS Internal
Topics

What does an Alert do ?


Characteristics of Alerts
Demo for Creating an Alert
Additional Information
Summary Message
History of Alert
Distribution Lists
Additional functionalities
Escalation Groups,
Threshold Group
Response Processing

TCS Internal
What does Oracle Alert do?
Oracle Alert is your complete exception control solution.
It informs you of critical activities in the database
Delivers key information from applications (ie HR, Payroll, etc) in the
format you choose
Provides regular reports via email instead of having to run reports
Automate system maintenance, and routine online tasks

You can define one of two types of alerts :


Periodic Alert
Checks the database for information according to a schedule you define.
Event Alert
Immediately notifies you of activity in the database as it occursVERY
USEFUL

TCS Internal
Periodic Alert

Characteristics of a periodic alert :

It is a SQL Statement that retrieves a specific database information


i.e.. sql to retrieve new hires who starts today, employees who
were terminated yesterday
You can specify the frequency that you want a periodic alert to run
the SQL statement
ie. Every Day, Every Other Day/Business Day, On Day of the
Week / Month, Every N Calendar/Business Days, On Demand.
Activities of a specific USER can be monitored without his
awareness
TCS Internal
Set up the actions you want Oracle Alert to perform once it
runs the SQL statement.
Types of Actions:
- Email with the retrieved information sent to recipient.
This is the most common action used.
- Running a SQL statement script ie. Update script
- Running a concurrent program
- Running an operating system script

Periodic Alert Scheduler will automatically execute the alert


at the time you have specified for it to be checked.

TCS Internal
Event Alert
Characteristics of an event alert :
It is a database event of an Insert or Update to a specific
database table
i.e. Insert to FND_USER_RESP_GROUPS table where
responsibility name like HR
You can specify the SQL select statement to retrieve specific
information as a result of the database event

TCS Internal
Event Alert
Characteristics of an event alert :
When an insert or update is done, the Event ALERT Database
trigger will fire; *BUT* no action will be done.
The trigger will exit immediately once it determines that the
'Event' is not being executed within an Application "context".

For each event alert database triggers are created. The trigger
name is created by prefixing the table name with ALR_ and
suffixing the table name with _IAR (after insert) or _UAR (after
update).

Query the DBA_TRIGGERS table for the trigger that is associated


with this event alert.

TCS Internal
Set up the actions you want Oracle Alert to perform as a result of
the database event.
Types of Actions:
- Email with the retrieved information sent to
recipient. The most common action used.
- Running a SQL statement script ie. Update script
- Running a concurrent program
- Running an operating system script

TCS Internal
Periodic Alert vs. Event Alert
Event Alert is less preferred because each database event (Insert or Update) that
occurs in an actively used table
ie. PER_ALL_PEOPLE_F,
PER_ALL_ASSIGNMENTS_F, etc
triggers a request to the Concurrent Manager queue, hence causing congestion to
the queue.

Periodic Alert is more desirable because each alert run sends only one request to
the Concurrent Manager, even though there might be more than one exception
found in the request

TCS Internal
To create an alert, you need:
Alert Manager Responsibility

TCS Internal
Periodic Alert Creation Demo

TCS Internal
How to Create a Periodic Alert

1. In Alert Manager, navigate to Alert > Define


This is an empty alert form

TCS Internal
Choose the Application that owns the alert ie. Oracle Human Resources
Enter Name & Description for the alert
Enabled flag for activation of alert. You can leave it unchecked until you are ready to run the
alert
Choose Periodic tab. Enter the Frequency and Start Time you want the alert to run.
Specify the number of days you want to keep the alert history logs in Keep Days.
Enter SQL statement in Select Statement. Format:
SELECT first_name INTO &firstname identify output with an & before name
FROM PER_ALL_PEOPLE_F
WHERE employee_number = 99999;
Choose Verify to parse the Select statement. The results will be displayed in a Note window.
Choose Run to execute the Select statement. It will display the number of rows returned in a
Note window.
Save your work.

TCS Internal
Example of Periodic Alert

TCS Internal
How to Create an Event Alert
1. Choose the Application that owns the alert ie. Oracle Human
Resources (could be AP/AR/FA/GL etc)
2. Enter Name & Description for the alert
3. Enabled flag for activation of alert. You can leave it unchecked until
you are ready to run the alert
4. Choose Event tab.
5. Choose the Application and database table you want Oracle Alert to
monitor.
6. Check After Insert and/or After Update if you want the event alert to run
when a user inserts and/or updates a row in the database table.
7. Specify the number of days you want to keep the alert history logs in
Keep Days.
8. Enter SQL statement in Select Statement

TCS Internal
Format: SELECT fnd.user_name
INTO &newuser
FROM FND_USER fnd
WHERE fnd.rowid = :ROWID;

The Select statement must include a join from the table where
the event transaction occurs (FND_USER) to an implicit input
called :ROWID. Oracle Alert uses :ROWID to pinpoint the
inserted or updated record in the table that caused the event. If
this join is not included, Oracle Alert cannot locate the row
where the event transaction occurred.

Choose Verify to parse the Select statement. The results will be


displayed in a Note window.
Choose Run to execute the Select statement. It will display the
number of rows returned in a Note window.
Save your work.

TCS Internal
Example of an Event alert

TCS Internal
Creating Alert Actions
After defining a Period or Event alert, you need to create
actions for the alert to perform. On the same alert form,
click on Actions button.
On the Actions form, select a level for Action: Detail,
Summary or No Exception.

TCS Internal
Detail Action - Performs once for each individual exception
Summary Action - Performs once for all exceptions found
No Exception - Performs when no exceptions are found
Choose Action Details button on Actions form. On the Action
Details page, select the type of action you want to create in the
Action Type field.

TCS Internal
Creating an Action Set Next, you need to include the
Alert Actions created previously
in an enabled Action Set for
Oracle Alert to perform during
an alert check. An Action Set
can include an unlimited number
of Actions and any combinations
of Actions.
Additionally, you can create as
many Action Sets as you like for
each alert. Oracle Alert
executes the alert SQL
Statement once for each Action
Set You defined. During each
action set check, Oracle Alert
executes each Action Set
Member in the sequence
specified.

To get to this form, click on Action Sets button on main alert form

TCS Internal
Specifying Alert Details
Click on Alert Details button on the main alert form.
On the Outputs tab, you will see the outputs of the Select Statement,
defined on the INTO clause.
Make sure they are lined up in the same order as they appear on the
Select Statement.

TCS Internal
Installation
Oracle ID - specify an Oracle ID if you want Oracle Alert to
check your alert against the specific Oracle ID. ie APPS
Operating Unit If alert is defined for US, choose the business group
Oracle Corporation. For Global Alerts, leave it blank.
Enabled flag to enable/disable the Installations.

TCS Internal
Running an Alert
To manually run a Periodic Alert, go to Request > Check

TCS Internal
Summary Message
Oracle Alert can perform a summary message action on a combination of the
exceptions found during an alert check, rather than on each exception found.

Separate summary message to the purchasing agent for each purchase order.

To: &AGENT
Cc:
Bcc:
Subject: Unapproved purchase order &PO

PO Number: &PO Vendor: &VENDOR


Description: &DESC

Line Item Description Quantity Price



=**= Enter summary template below this line =**=

** &LINE &ITEM &QTY $&PRICE

=**= Enter summary template above this line =**=

TCS Internal
History of an Alert

To view action logs of any alert, go to Menu Item History

TCS Internal
Distribution Lists
predefine a set of message recipients for use on many actions.
To create, click on Distribution list in navigator

BCC: Can be used for a person


Confidential to Management

TCS Internal
Transfer Alert
Transfer an alert definition to another database, or make a copy of an existing alert.
Click on the Menu Tools->Transfer Alert from the main alerts window.

TCS Internal
Threshold Group
automatically determine whether to perform a detail or summary action,
depending upon the number of exceptions found by the alert Select
statement.

TCS Internal
Escalation
Oracle Alert performs a different detail action each time it encounters
the same exception, corresponding to increasing severity levels.

TCS Internal
Associating Threshold and Escalation
Groups with Action Set

TCS Internal
Duplicate Checking for Escalation
Oracle Alert cannot check for duplicates if history for the previous alert
checks is not retained.

We can choose outputs for checking duplicates at Alert and Action set
level.

If you check the Suppress Duplicates check box in the Actions Sets
window of the Alerts form, Oracle Alert no longer performs any action
within that escalation group, after reaching the highest escalation level.

TCS Internal
Response Processing
When Oracle Alert receives a response to a specific alert message,
it automatically performs the actions you define.
Actions can be defined for valid and invalid responses.
Oracle Alert lets you define responses that may include response
variables whose values are provided by the responder.
Oracle Alert lets you define followup actions that Oracle Alert
takes if the message recipient does not respond within specified
number of days
Once a valid response is received for a message the further
response processing is not done for it. Oracle Alert uses message
handle for this.
#:<Oracle_Alert_installation_number.message_number.Oracle_ID.organization_ID>
e.g. 2.347.3.5

TCS Internal
Response Set
Response Set consists of response variables, valid response definitions, actions,
Invalid response actions and follow-up actions.
Click on Response Set button from the main alert window

TCS Internal
Attaching Response Set to an Action

TCS Internal
Thank You

TCS Internal

S-ar putea să vă placă și