From: dforum <dforums@vieonet.com>
To: pgsql-performance@postgresql.org
Subject: NOW vs CURRENT_DATE
Date: Sun, 24 Aug 2008 22:01:55 +0200
Message-ID: <48B1BE33.3060505@vieonet.com> (raw)
Hello every body,
I just discover a big not only big huge difference between NOW() and
CURRENT_DATE.
Did you already know about it and do you know why ?
DELETE FROM blacklist where bl_date < (NOW() - interval '2 DAY');
on 6 000 000 of records
699 ms
DELETE FROM blacklist where bl_date < (CURRENT_DATE - interval '2 DAY');
on 6 000 000 of records
0.065 ms
tx
david
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: dforums@vieonet.com
Subject: Re: NOW vs CURRENT_DATE
In-Reply-To: <48B1BE33.3060505@vieonet.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox