pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>
Cc: David Jarvis <thangalin@gmail.com>
Cc: pgsql-performance@postgresql.org, Magnus Hagander <magnus@hagander.net>
Subject: Re: Analysis Function
Date: Sun, 13 Jun 2010 11:34:20 -0400
Message-ID: <13998.1276443260@sss.pgh.pa.us> (raw)
In-Reply-To: <4C14746F.9050603@enterprisedb.com>
References: <AANLkTikihIMleazgqo1NhLo7LA5Tiujz4TIfBL1agxAp@mail.gmail.com>
	<AANLkTikZKwBCR8QfGph3aH34A2dJ2NQyOjq-Pt3eZ3_z@mail.gmail.com>
	<4C119B3E.3090608@squeakycode.net>
	<AANLkTinjUmGWmB3jsjj-6w_44c0K7f_wSrH_1TALPaOY@mail.gmail.com>
	<m34ohahrp4.fsf@passepartout.tim-landscheidt.de>
	<AANLkTik3l6uedzVJLqn-nueNva46NAFwxbpSe1XSc26_@mail.gmail.com>
	<m3typ9hl6a.fsf@passepartout.tim-landscheidt.de>
	<AANLkTikPcYh1vMxVynxGnD4RCch8-DMixiGK1v9kO17Z@mail.gmail.com>
	<AANLkTim6TrfgLiXM3sTSx6rgXQ3zNLTWBTD_MbU0OPsv@mail.gmail.com>
	<12241.1276287655@sss.pgh.pa.us>
	<AANLkTil8w33uYIadqvvecTEvTmY9aNvstpuiy1tryyT7@mail.gmail.com>
	<AANLkTinPNQZv_9BS1fkoLPXzcBZe8FFv77PBRhPR-GpL@mail.gmail.com>
	<4C14746F.9050603@enterprisedb.com>

Heikki Linnakangas <heikki.linnakangas@enterprisedb.com> writes:
> We could have a function like:

> construct_timestamp(year int4, month int4, date int4, hour int4, minute 
> int4, second int4, milliseconds int4, timezone text)

This fails to allow specification to the microsecond level (and note
that with float timestamps even smaller fractions have potential use).
I would suggest dropping the milliseconds argument and instead letting
the seconds arg be float8.  That seems a closer match to the way people
think about the textual representation.

> Now that we have named parameter notation, callers can use it to 
> conveniently fill in only the fields needed:

It's not immediately obvious what the default value of "timezone"
will be?

			regards, tom lane



view thread (30+ messages)  latest in thread

Message-ID: <13998.1276443260@sss.pgh.pa.us>
Permalink:  ../13998.1276443260@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/13998.1276443260@sss.pgh.pa.us

 · 

reply

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: tgl@sss.pgh.pa.us, heikki.linnakangas@enterprisedb.com, thangalin@gmail.com, magnus@hagander.net
  Subject: Re: Analysis Function
  In-Reply-To: <13998.1276443260@sss.pgh.pa.us>

* 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