Postgresql select join by date - Join rows where a timestamp value is equal to midnight of the date
SELECT t1.*
FROM t1
JOIN t2 ON (
t1.t2_id = t2.id AND
t1.date_field::TIMESTAMP = t2.datetime_field AT TIME ZONE 'Europe/London'
)
Postgresql select join by date - Join rows where a timestamp value is equal to midnight of the date
SELECT t1.*
FROM t1
JOIN t2 ON (
t1.t2_id = t2.id AND
t1.date_field::TIMESTAMP = t2.datetime_field AT TIME ZONE 'Europe/London'
)
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us