cancel
Showing results for 
Search instead for 
Did you mean: 

Schedule based events

Former Member
0 Kudos

Hi,

     I am scheduling a report from Central Management Console and creating a schedule based event. I want to run a .bat file (success.bat) when the report is successful and another file (failure.bat) when the report has failed. But I don't want to create two separate schedule based events for success and failure. I want to create one event which will be triggered when the report is complete. The event should check whether the report is successful, if so run success.bat, otherwise run failure.bat. How should I do that?

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Harris,

I think the above requirement can be fullfilled using the below methods:

For this we have to have create two Schedule based events as Schedule based event can be triggered having these three conditions:

  • Success.
  • Failure.
  • Success or Failure

Once the Schedule based Event is created  we have to create a Program Object

Steps to Create a Program Object

  1. Logon to CMC.
  2. Click Applications.
  3. Right-click on Central Management Console.
  4. Click on Program Object Rights.
  5. Select Run scripts/binaries.
  6. Select Schedule with the following operating system credentials and enter necessary credential information.
  7. Click Save & Close.
  8. Select Folders.
  9. Select a folder of your choice.
  10. Click Manage > Add > Program File.
  11. Click Browse and select the batch file you created earlier.
  12. Select Program type: Executable(binary, batch, shell script).
  13. Select a category of your choice.

Schedule a report

  1. Logon to CMC.
  2. Click Folders.
  3. Select a report that you want to schedule.
  4. Click Actions > Schedule.
  5. Click Events.
  6. Select the Schedule-based event you created earlier.
  7. Click > and add it to Events to trigger on completion: list.
  8. Satisfy other schedule conditions you desire.
  9. Click Schedule.

Schedule a Program file

  1. Logon to CMC.
  2. Click Folders.
  3. Select a Program that you want to schedule.
  4. Click Actions > Schedule.
  5. Click Events.
  6. Select the schedule-based event you created earlier.
  7. Click > and add it to Events to wait for: list.
  8. Satisfy other schedule conditions you desire.
  9. Click Schedule.

Let me know if I correctly understood your requirement.

Regards

Former Member
0 Kudos

Ya Sumeet its correct. Thank You.

Answers (2)

Answers (2)

Former Member
0 Kudos

I don't think it is possible to trigger batch file based on the schedule status with the default product options..

we can have Email to know the schedule status. but not batch file based on the schedule status

Former Member
0 Kudos

Hi Haris,

While scheduling a report you can use Notification option which can help you notify the sucess or failure of report via email or Auditing functionality.

Is you requirement that any report that schedules should notify about its sucess and failure which should be handled by the batch file?

Rgds,

Unmesh

Former Member
0 Kudos

Hi Unmesh,

     My requirement is just to run a batch file. There are two separate batch files, success.bat and failure.bat. success.bat should run when the report is successful, otherwise failure.bat should be executed.

Also, I don't need to send any email about success or failure.

Former Member
0 Kudos

Please refer to article 1304635 - How to start the scheduling of a report after the

successful scheduling of another report based on events?

It may help you.