All Products
Search
Document Center

Simple Log Service:Query Scheduled SQL results

Last Updated:Mar 25, 2026

This topic describes how to query the results of a Scheduled SQL job in a destination Logstore or Metricstore.

Prerequisites

You have created a Scheduled SQL job.

Query results in a destination Logstore

You can query the results of a Scheduled SQL job in the destination Logstore by using the job name.

  1. Log on to the Simple Log Service console.

  2. Obtain the name of the Scheduled SQL job.

    1. In the Projects section, click the project you want.

    2. In the left-side navigation pane, choose Job Management > Scheduled SQL. In the Scheduled SQL list, click the destination job.

    3. On the Basic Information tab, obtain the job name.

      查询Scheduled SQL结果数据

  3. Query the job results.

    1. Go to the destination Logstore. For more information, see Quick start for Search & Analyze.

    2. In the search box, enter __tag__:__job__: job-name.

      Replace job-name with the job name that you obtained in step 2.

    3. Click 15 Minutes (Relative) to set the time range for your query.

      Note

      If no data is returned, expand the time range.

    4. Click Search & Analyze.

      查询Scheduled SQL结果数据

Query results in a destination Metricstore

You can query the results of a Scheduled SQL job in the destination Metricstore by using the metrics that you defined in the job.

  1. Log on to the Simple Log Service console.

  2. In the Projects section, click the one you want.

    image

  3. On the Metric Storage > Metricstores tab, click the metricstore you want.image

  4. Click 15 Minutes (Relative) to set the time range for your query.

    Note

    If no data is returned, expand the time range.

  5. Enter a query statement for the relevant metric and click Execute Now.

    The metric is the one that you specified when you created the Scheduled SQL job.

    查询Scheduled SQL结果数据