In response to Andreas :
>
> A. Kretschmer schrieb:
> >[...] Or simpler:
> >
> >test=*# select ((d-'2009-10-02'::date)/14) || '. period' as period,
> >sum(value) from foo group by 1;
> >
> This is tricky, because you use a text-column to sort but need numerical
> sorting since there will be m
A. Kretschmer schrieb:
[...] Or simpler:
test=*# select ((d-'2009-10-02'::date)/14) || '. period' as period, sum(value)
from foo group by 1;
This is tricky, because you use a text-column to sort but need numerical
sorting since there will be more than 0-9 periods.
This is still the way
In response to Andreas :
> Hi,
>
> I need some magic for a moving statistic that works on a rather big
> table starting at a given date within the table up until now.
> The statistic will count events allways on fridays over periods of 2
> weeks before ... biweekly?
> So I'd like to get a line e