Google Bigquery Subtract hours from date
To Subtract an hour from a DATETIME column:
SELECT
DATETIME_SUB(CURRENT_DATETIME(), INTERVAL 1 HOUR)
For TIMESTAMP Columns:
SELECT
TIMESTAMP_SUB(CURRENT_TIMESTAMP(), INTERVAL 1 HOUR)
dan-irving
posted on 01 Feb 21Enjoy great content like this and a lot more !
Signup for a free account to write a post / comment / upvote posts. Its simple and takes less than 5 seconds
Post Comment