Configuring Query Schedules
You can schedule the execution of your queries and set the frequency of execution.
- Procedure
- Open the Scheduled Queries page in one of the following ways:
- On the Scheduled Queries page, click a query to open its Details pane.
- On the Details pane, click Edit. On the Edit Scheduled Query page, configure the query schedule.
- To add a schedule, click the plus icon + or the Add Schedule button. The default schedule name is displayed, but you can change it, if required.
- In the
Time Frame section, enter the following information.
Field Description Run Select one of the following frequency types: Frequency Type Description Once every few hours Select the hourly interval from the Hourly Interval drop-down list. Once a day Select the time of the day from the At drop-down list. Once every few days - Select the number of days from the Interval drop-down list.
- Select the time of the day from the At drop-down list.
Once a week - Select the time of the day from the At drop-down list.
- Select the day of the week from the Every drop-down list.
Once a month - Select the time of the day from the At drop-down list.
- Select the day of the month from the Every drop-down list. You can also select Last day of the month.
For the Period Type the period on which the query should be executed. The default value is -12h. For valid time ranges, see Time Range Expressions. - To run the query immediately, click
Run Now.
Note: The Run Now button is enabled only when you are editing a schedule that has already been saved earlier.The previous and next execution time is displayed in the Previous Execution and Next Execution fields.
- In the
Number of reports to be saved in the system field, enter the number of execution results that you would like to be stored in the system.
To view the stored reports, click View Executions. From the Executions page you can delete or download selected reports as a CSV file.Note: The View Executions link is visible only when you are editing a schedule that has already been saved earlier. The link is not available when adding a new schedule.
- (Optional)
Email Recipients section: If you want the report to be sent by email, enter the name and email ID of the email recipients and click the check mark to save. You can send the email attachments as a PDF, HTML, or CSV file.
- If a user with the name and email ID is found in the database, the login name of the user is filled automatically in the Login Name field.
- The file name of the attachment includes the schedule name followed by the date and time when the email is sent. The file name format is
<scheduleName><date>T<time>.<fileExtension>
. For example, CiscoASA_Schedule_1_2019-12-23T01:03:22.226017.csv. - The attachments are compressed before being attached to the email. If the attachment size is more than the maximum permitted value, the email does not include the attachment. You must download the attachment from the Executions page. To have the attachment size limit increased, contact your administrator.
- If the number of columns you selected or the content within the columns is too large, then the PDF report might be distorted. In such a case, reduce the number of selected columns. Otherwise, select the CSV or HTML format as the report type.
Tip: If there is any error while executing the query or sending emails, an error icon is displayed. Hover over the error icon to read the error messages.If you do not receive an email, then check if the mail has been redirected to the Spam folder.