Amazon Redshift でクエリを実行しても SVL_QUERY_METRICS に記録されない場合

SVL_QUERY_METRICS は STL_QUERY_METRICS を参照しており、STL_QUERY_METRICS は1 秒未満で実行されるクエリセグメントは記録されない場合があるためと思われる。

Contains metrics information, such as the number of rows processed, CPU usage, input/output, and disk use, for queries that have completed running in user-defined query queues (service classes). To view metrics for active queries that are currently running, see the STV_QUERY_METRICS system view.

Query metrics are sampled at one second intervals. As a result, different runs of the same query might return slightly different times. Also, query segments that run in less than one second might not be recorded.

STL_QUERY_METRICS - Amazon Redshift

SVL ビューは STL ビューのみを参照している。

STL views are generated from logs that have been persisted to disk to provide a history of the system. STV views are virtual views that contain snapshots of the current system data. They are based on transient in-memory data and are not persisted to disk-based logs or regular tables. System views that contain any reference to a transient STV table are called SVV views. Views containing only references to STL views are called SVL views. SYS views are system views that you can use to monitor a serverless endpoint.

Types of system tables and views - Amazon Redshift