Re: Generating a list of days - Mailing list pgsql-general

From wsheldah@lexmark.com
Subject Re: Generating a list of days
Date
Msg-id 200203201521.KAA16449@interlock2.lexmark.com
Whole thread Raw
In response to Generating a list of days  (Fraser Murray <frasernm@yahoo.co.uk>)
List pgsql-general

I know you said you'd prefer SQL, but perl can do this very easily using
Time::Piece or one of the other date modules that support date arithmetic, in a
very natural way. Sure you want to use SQL for this?

Wes Sheldahl



Fraser Murray <frasernm%yahoo.co.uk@interlock.lexmark.com> on 03/15/2002
03:51:11 AM

To:   pgsql-general%postgresql.org@interlock.lexmark.com
cc:    (bcc: Wesley Sheldahl/Lex/Lexmark)
Subject:  [GENERAL] Generating a list of days


Hi,

I'm trying to generate a list of days between a start
date and an end date for use in a query - I would then
do an outer join with some other data for graphing
purposes as I need all the days with 0 entries.

I using perl as the front-end, but I'd rather do it in
sql if poss.

Any ideas?

TIA

Fraser

__________________________________________________
Do You Yahoo!?
Yahoo! Sports - live college hoops coverage
http://sports.yahoo.com/

---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster





pgsql-general by date:

Previous
From: Jeff Eckermann
Date:
Subject: Re: How to create crude report with psql and/or plpgsql
Next
From: Thomas Lockhart
Date:
Subject: Re: Bad timestamp external representation '2001-05-11