Q

How to set up a job for an SQL query in Oracle 10g Grid Control

Oracle expert Brian Peasland explains when and how to set up a job in Oracle to run an SQL statement.

This Content Component encountered an error
Regarding Oracle 10g Grid Control, is there a way to run adhoc SQL within Grid without having to set up a job to execute it?
The term "adhoc" means designed for the specific purposes of that specific task at that specific time. If you want to run a SQL statement at a regular interval, then the query is not considered "adhoc".

Oracle's preferred method of running SQL statements at a regularly scheduled time is to set up a job. In Oracle 10g+, you can use the DBMS_SCHEDULER package for this task.

Alternatively, you can set up a batch program or shell script which uses SQL*Plus to run the SQL statement. Once the program or script is created, it can be scheduled with Windows task scheduler or from cron in Unix/Linux.

This was first published in July 2008

Dig deeper on Oracle database administration

Pro+

Features

Enjoy the benefits of Pro+ membership, learn more and join.

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

0 comments

Oldest 

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to:

-ADS BY GOOGLE

SearchDataManagement

SearchBusinessAnalytics

SearchSAP

SearchSQLServer

TheServerSide

SearchDataCenter

SearchContentManagement

SearchFinancialApplications

Close