Skip to content

Instantly share code, notes, and snippets.

@ludndev
Created September 29, 2024 11:00
Show Gist options
  • Save ludndev/46007ba69e0ae3ead5f18fc8be8a2d79 to your computer and use it in GitHub Desktop.
Save ludndev/46007ba69e0ae3ead5f18fc8be8a2d79 to your computer and use it in GitHub Desktop.
# check if token exists and is valid, return RPC with bool and user_id
query = r"""
select NOW() as n_direct, NOW() AT TIME ZONE 'UTC' as n_utc;
"""
cur.execute(query, (hashed_token,))
result = cur.fetchone()
cur.close()
print(result)
@ludndev
Copy link
Author

ludndev commented Sep 29, 2024

this NOW() AT TIME ZONE 'UTC' is actually working and returning expected value.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment