On the Scheduled SQL page in the Log Service console, you can view the basic information about a Scheduled SQL job and the instances of the Scheduled SQL job. You can also retry, modify, or delete the Scheduled SQL job.

Prerequisites

A Scheduled SQL job is created. For more information, see Import data from Logstore to Logstore, Import data from Logstore to Metricstore, or Import data from Metricstore to Metricstore.

Procedure

  1. Log on to the Log Service console.
  2. In the Projects section, click the name of the project that you want to view.
  3. In the left-side navigation pane, choose Jobs > Scheduled SQL.
  4. Click the Scheduled SQL job.

View the basic information about the Scheduled SQL job

In the Basic Information section, you can view the basic information about the Scheduled SQL job, including Created At, Last Modified At, and Task ID.

Scheduled SQL job

View the instances of the Scheduled SQL job

When the Scheduled SQL job is run, Log Service generates instances based on the scheduling interval that you specify. You can view all instances of the Scheduled SQL job in the Instances section.

Instances
Parameter Description
Instance ID The unique identifier of the Scheduled SQL instance.
Task Running Time The time range during which the Scheduled SQL instance is run.
SQL Query Range The time range that you specify for SQL analysis. The instance analyzes the data that is generated within the time range.
Processed Data Size The size of the data involved in SQL analysis. The following information is displayed:
  • Processed Rows: the number of logs that the instance reads within the specified SQL time window. This parameter indicates the amount of data that is used in computation.
  • Result Rows: the number of logs in the analysis results. This parameter indicates the amount of data that is written to the destination Logstore or Metricstore.
  • Processed Date Size: the number of bytes of logs that the instance reads within the specified SQL time window. This parameter indicates the amount of data that is used in computation.
  • Rows Written to Destination Logstore: the number of logs that are obtained from the analysis results and written to the destination Logstore or Metricstore. This parameter indicates the amount of data that is written to the destination Logstore or Metricstore.
Status The status of the Scheduled SQL instance. Valid values: Running, Retrying, Success, and Failed.

Retry an instance of the Scheduled SQL job

If an instance of the Scheduled SQL job is in the Success or Failed state, you can run the instance again. For example, if an instance is in the Failed state due to invalid authorization, you can modify the authorization settings of the Scheduled SQL job and click Retry.
Notice If one or more instances are run to process historical data, you can retry successful instances. However, we recommend that you do not retry successful instances. In most cases, you need to retry only the failed instances of a Scheduled SQL job.

Delete the Scheduled SQL job

If you no longer need to use the Scheduled SQL job, you can click Delete in the upper-right corner of the Scheduled SQL page.

Warning After you delete the Scheduled SQL job, the job cannot be restored. Proceed with caution.

Modify the Scheduled SQL job

To modify the settings of the Scheduled SQL job, click Modify Settings in the upper-right corner of the Scheduled SQL page. For more information about the parameters, see Import data from Logstore to Logstore, Import data from Logstore to Metricstore, or Import data from Metricstore to Metricstore.