pg.ddx.io pgsql-sql@postgresql.org mailing list archive
help / color / mirror / Atom feeddefault for date/time types
2+ messages / 2 participants
[nested] [flat]
* default for date/time types
@ 2000-03-06 06:28 Seth Banks <seth@subimage.com>
0 siblings, 1 reply; 2+ messages in thread
From: Seth Banks @ 2000-03-06 06:28 UTC (permalink / raw)
To: pgsql-sql
hello,
if i were to setup a date or time type in my database, what would be a good
default value to use (an empty one, but not null)
thanks!
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: [SQL] default for date/time types
@ 2000-03-06 07:09 Peter Eisentraut <e99re41@DoCS.UU.SE>
parent: Seth Banks <seth@subimage.com>
0 siblings, 0 replies; 2+ messages in thread
From: Peter Eisentraut @ 2000-03-06 07:09 UTC (permalink / raw)
To: Seth Banks <seth@subimage.com>; +Cc: pgsql-sql
On Sun, 5 Mar 2000, Seth Banks wrote:
> if i were to setup a date or time type in my database, what would be a
> good default value to use (an empty one, but not null)
The way you're asking you probably do want to use NULL because there's no
such thing as an "empty date". NULL is supposed to fill exactly that gap.
However, if for some reason you really can't use NULL then consider
perhaps 'invalid' or '-infinity' but these are distinctly non-portable and
might not buy you much in terms of elegance. Implementor beware. :)
--
Peter Eisentraut Sernanders väg 10:115
peter_e@gmx.net 75262 Uppsala
http://yi.org/peter-e/ Sweden
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2000-03-06 07:09 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2000-03-06 06:28 default for date/time types Seth Banks <seth@subimage.com>
2000-03-06 07:09 ` Peter Eisentraut <e99re41@DoCS.UU.SE>
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