On Wed, 2 May 2007, Lew wrote:
The best solution I've encountered so far to this type of problem is to
have a table of "days" with columns like isWeekday, isHoliday, julianDay,
otherTidbit, ...
Then you select or join the days within the interval of interest and
factor out weekdays, or holidays
John D. Burger wrote:
There was a brief discussion of this just last week, with a few solutions
suggested:
http://archives.postgresql.org/pgsql-general/2007-04/msg01098.php
Rich Shepard wrote:
That thread asked how to find business days between any two specified
dates. I would like to creat
Rich,
I would think that as an ecologist, you would have a better sense than most
here of the kinds of things I'd be doing. After all, I am a mathematical
ecologist by training and the majority of applications I have developed have
been either for agricultural consultants or environmental
On Mon, 30 Apr 2007, Ted Byers wrote:
I am not sure I see why it would be good to do this using SQL, but I do
know that I have used a number of Perl packages for this sort of thing.
I am not arguing with you. I just want to know in what circumstances my
schemas can be improved by a calendar
On Mon, 30 Apr 2007, John D. Burger wrote:
There was a brief discussion of this just last week, with a few solutions
suggested:
http://archives.postgresql.org/pgsql-general/2007-04/msg01098.php
John,
That thread asked how to find business days between any two specified
dates. I would like
I am not sure I see why it would be good to do this using SQL, but I do know
that I have used a number of Perl packages for this sort of thing. When I have
done this in the past, I'd do the date and time calculations in Perl and feed
the result to whatever RDBMS I happen to be using (PostgreSQL
On 4/28/07, Rich Shepard <[EMAIL PROTECTED]> wrote:
I would like to store a temporal frequency as NUMERIC, without units, and
have the application's front end (or middleware) transform the number to the
appropriate interval name. I'm having difficulties figuring out how to do
this.
This is a
Rich Shepard wrote:
I wonder if a workweek/holiday calendar table for PostgreSQL already
exists. If not I need to track down the procedure for creating one
as Joe
Celko references such a calendar in his books. I think that any
schema that
has temporal components needs such a table.
There
On Mon, 30 Apr 2007, Brent Wood wrote:
If I'm following this correctly, then interval & extract timepart can be
used to provide all the required functionality:
Thanks, Brent. Your suggestions complete the approach I was considering.
There is no need for real-time response, to checking after
Listmail wrote:
On Sun, 29 Apr 2007 22:33:37 +0200, Rich Shepard
<[EMAIL PROTECTED]> wrote:
On Sun, 29 Apr 2007, Martijn van Oosterhout wrote:
Then I'm afraid you havn't indicated your requirements properly. All
I can
see is that the interval type does exactly what you want. It can store
On Sun, 29 Apr 2007 22:33:37 +0200, Rich Shepard
<[EMAIL PROTECTED]> wrote:
On Sun, 29 Apr 2007, Martijn van Oosterhout wrote:
Then I'm afraid you havn't indicated your requirements properly. All I
can
see is that the interval type does exactly what you want. It can store
days, weeks, mont
On Sun, 29 Apr 2007, Rich Shepard wrote:
How does one define 'shift' with intervals? 0.33 DAY?
On further reflection, I understand how to make the interval 'day' work by
comparing the current timestamp with the month and hour. If there's no
record within the necessary range, a message is e-
On Sun, 29 Apr 2007, Martijn van Oosterhout wrote:
Then I'm afraid you havn't indicated your requirements properly. All I can
see is that the interval type does exactly what you want. It can store
days, weeks, months or any combination thereof. You can multiply them and
add them to dates and all
On Sun, Apr 29, 2007 at 07:43:52AM -0700, Rich Shepard wrote:
> Alexander's reference to the internal postgres interval support as different
> from the SQL standard INTERVAL. If so, it's my mis-writing.
>
> Regulatory requirements are that monitoring is to be done 'once per
> shift,' 'daily,' 'w
On Sun, 29 Apr 2007, Tom Lane wrote:
What gives you the idea that type INTERVAL is Postgres-specific? It's in
the SQL standard.
Tom,
I know that and that was not to what I referred. Perhaps I mis-understood
Alexander's reference to the internal postgres interval support as different
from th
Rich Shepard <[EMAIL PROTECTED]> writes:
>If the requirements were in days, weeks, and months I could probably find
> a time unit that worked -- including the PostgreSQL-specific solution.
What gives you the idea that type INTERVAL is Postgres-specific?
It's in the SQL standard.
On Sun, 29 Apr 2007, Alexander Staubo wrote:
This is a common enough problem. Three factors come to mind:
(1) Can all your intervals be expressed in absolute time units, such as
number of days? "Work shift" is a human concept whose length is defined by
context.
Alexander,
If the requiremen
On 4/28/07, Rich Shepard <[EMAIL PROTECTED]> wrote:
I would like to store a temporal frequency as NUMERIC, without units, and
have the application's front end (or middleware) transform the number to the
appropriate interval name. I'm having difficulties figuring out how to do
this.
This is a
I would like to store a temporal frequency as NUMERIC, without units, and
have the application's front end (or middleware) transform the number to the
appropriate interval name. I'm having difficulties figuring out how to do
this.
For example, an event might occur once per work shift, day, we
19 matches
Mail list logo