Re: Re: First Saturday and Last Saturday of a month - Mailing list pgsql-general

From Tom Lane
Subject Re: Re: First Saturday and Last Saturday of a month
Date
Msg-id 21131.997323119@sss.pgh.pa.us
Whole thread Raw
In response to Re: First Saturday and Last Saturday of a month  (Allan Engelhardt <allane@cybaea.com>)
List pgsql-general
Allan Engelhardt <allane@cybaea.com> writes:
> Last Saturday problem is similar to above except for some sign
> reversals, but more interesting as you need the number of days in the
> month.

I'd be inclined to take the first day of the *next* month (relatively
easy to figure), and then back up to a Saturday using the 'dow' value
for that day.

            regards, tom lane

pgsql-general by date:

Previous
From: "Yusron Hilmy"
Date:
Subject: getting result information of DECLARE CURSOR statement
Next
From: Allan Engelhardt
Date:
Subject: Re: Re: First Saturday and Last Saturday of a month