MSCEWI3135

Data Retention Period May Produce No Results

This is a deprecated version of the SnowConvert documentation, please visit the official site HERE.

Severity

Low

Description

If a query is executed in Snowflake using time travel, it could return no results if the specified time is no longer in the range of the data retention period. We recommend to read more about Snowflake's Time Travel.

Example code

Input code

SELECT * FROM employees
AS OF SCN
TO_TIMESTAMP('2023-09-27 07:00:00', 'YYYY-MM-DD HH:MI:SS')
WHERE last_name = 'SampleName';

Output code

SELECT * FROM
employees
--** MSC-WARNING - MSCEWI3135 - DATA RETENTION PERIOD MAY PRODUCE NO RESULTS **
AT (TIMESTAMP =>
TO_TIMESTAMP('2023-09-27 07:00:00', 'YYYY-MM-DD HH:MI:SS'))
WHERE last_name = 'SampleName';

Recommendations

Last updated