SQL Resources
SQL
CURRENT_DATETIME

CURRENT_DATETIME

Definition

The BigQuery CURRENT_DATETIME function returns the date and time at the moment the query is evaluated. By default the date time will be in UTC timezone but a specific timezone can be selected.

Syntax

CURRENT_DATETIME([time_zone])
SELECT
  CURRENT_DATETIME() AS datetime_utc,
  CURRENT_DATETIME('Australia/Sydney') AS datetime_sydney,
  CURRENT_DATETIME('+08:00') AS datetime_plus_8
datetime_utcdatetime_sydneydatetime_plus_8
2021-02-12T12:26:04.8445462021-02-12T23:26:04.8445462021-02-12T20:26:04.844546

Practical Info

  • The returned data type is a DATETIME.
  • The full list of supported timezone names can be found here.
  • If the time_zone argument is NULL the function returns NULL.
  • Related Pages

  • CURRENT_DATE
  • CURRENT_TIMESTAMP
  • Subscribe to newsletter

    Subscribe to receive the latest blog posts to your inbox every week.

    By subscribing you agree to our Privacy Policy.
    Thank you! Your submission has been received!
    Oops! Something went wrong while submitting the form.

    Start solving your organization's biggest problems with Count today.

    Stay up to date with all things count, data and problem solving.