From: Michael Glaesemann <grzm@seespotcode.net>
To: Scott Marlowe <scott.marlowe@gmail.com>
Cc: A. Kretschmer <andreas.kretschmer@schollglas.com>
Cc: pgsql-sql@postgresql.org
Subject: Re: Optimize querry sql
Date: Sat, 15 Sep 2007 09:25:46 -0500
Message-ID: <02B986A3-8CED-4140-AE23-C1928041A822@seespotcode.net> (raw)
In-Reply-To: <dcc563d10709140817l50fae6aah40ff3a1b681e5bb4@mail.gmail.com>
References: <bc40d0a30709140131u3f23c6e1h17b8bf1f96235a91@mail.gmail.com>
<20070914084952.GB7443@a-kretschmer.de>
<dcc563d10709140636p452e73d0y32b2a6f6fd5166c2@mail.gmail.com>
<20070914145202.GA24546@a-kretschmer.de>
<dcc563d10709140817l50fae6aah40ff3a1b681e5bb4@mail.gmail.com>
On Sep 14, 2007, at 10:17 , Scott Marlowe wrote:
> OK, I was just afraid there was some "bad thing" TM that I wasn't
> aware of with now(), which, btw, I use all the time. whew.
I use CURRENT_TIMESTAMP and CURRENT_DATE for three reasons:
* they're SQL-standard keywords, unlike now(). This might make it
more portable, but I'm not planning on using another backend any time
soon.
* I think it's clearer to distinguish between timestamps and dates
* I don't like the look of now() with the parens.
Not that these are necessarily good reasons, but they're mine :). I
haven't measured it, but there might actually be (a very small bit
of) overhead in calling CURRENT_TIMESTAMP and CURRENT_DATE as they're
converted to now(), so that's one potential reason not to use them.
Michael Glaesemann
grzm seespotcode net
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-sql@postgresql.org
Cc: grzm@seespotcode.net, scott.marlowe@gmail.com, andreas.kretschmer@schollglas.com
Subject: Re: Optimize querry sql
In-Reply-To: <02B986A3-8CED-4140-AE23-C1928041A822@seespotcode.net>
* 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