Forum Stats

  • 3,873,041 Users
  • 2,266,499 Discussions


Need Help with Scheduling, Saving, and Emailing a Report From Apex

728812 Member Posts: 1
edited Oct 19, 2009 3:20PM in APEX Discussions
My ultimate goal is to schedule a report to be created in apex, save it to the database (in pdf), and then email it.
I can schedule the proc which underlies the report. I can send an email from the databse. But I don;t know how to do all three of these in an automated fashion via apex. Any help would be greatly appreciated.


  • dfcii
    dfcii Member Posts: 391
    Good afternoon,

    I run this type of process in a complete Windows environment - the client was Windows XP and the Database & Application Server were both Windows Server 2003.

    Typically, I would build a .BAT file within a Page Procedure that included a line to run the report, saving to a .PDF file and then generate a sql statement that would send an email to the user. In your case, you would want to email the .PDF as an attachment. My email was a notification that the report was ready for them to download and they would access their FTP folder.

    You can then schedule the .BAT file to run using the Oracle Scheduler to have that process run as an executable. The scheduler allows you set the date/time the process should run. To do this, your user must have CREATE JOB and CREATE EXTERNAL JOB privileges to run external jobs. (see the Oracle DB Admin manual for further details).

    Good luck,

    You can reward this reply by marking it as either Helpful or Correct :)
This discussion has been closed.