datetime query issue

From: Frank Joerdens <frank(at)x9media(dot)com>
To: pgsql-sql(at)postgreSQL(dot)org
Subject: datetime query issue
Date: 1999-08-28 13:35:07
Message-ID: 19990828153506.A18896@shark.x9media.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

I'm not sure how to go about this: I want to find all rows with a timestamp
between, say 6 a.m. and 10 p.m. for any number of days. The column format is
datetime. How do I extract the 'time of the day' information from this
column? What I can think of is to create a view for every single day where datetime
is > 6 and < 10 and then another query on all views together but that doesn't sound
very elegant and would be a real memory hog for a large number of days.

Any better ideas?

Thanks

Frank

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message tjk@tksoft.com 1999-08-28 18:23:51 Re: [SQL] datetime query issue
Previous Message Ross J. Reedstrom 1999-08-27 22:11:40 Re: [SQL] Newbie dbadmin out of his league