Creating a job scheduled based on a specific timezone

jobsoracletimezone

I have an Oracle database hosted in Europe. I need to create a scheduled job in the database to send email. I need to send email daily at 17:30:00 in India standard time (IST).

I know how to send email and create jobs. But don't know how to create a job to execute on my local time (IST).

How can I do this?

Best Answer

The following creates a job to execute daily at 17.30 local time specified by country.

BEGIN
  DBMS_SCHEDULER.CREATE_JOB (
   job_name           =>  'update_sales',
   job_type           =>  'STORED_PROCEDURE',
   job_action         =>  'OPS.SALES_PKG.UPDATE_SALES_SUMMARY',
   start_date         =>  '07-AUG-13 17.30.00 PM India/Delhi',
   repeat_interval    =>  'FREQ=DAILY',
   end_date           =>  '07-AUG-14 17.30.00 PM India/Delhi',
   auto_drop          =>   FALSE,
   job_class          =>  'batch_update_jobs',
   comments           =>  'My new job');
END;
/