calculations for interval and time/timetz to behave sanely for both
integer and float timestamps; up to now I think it's been doing
something pretty strange...
24 hours. This is very helpful for daylight savings time:
select '2005-05-03 00:00:00 EST'::timestamp with time zone + '24 hours';
?column?
----------------------
2005-05-04 01:00:00-04
select '2005-05-03 00:00:00 EST'::timestamp with time zone + '1 day';
?column?
----------------------
2005-05-04 01:00:00-04
Michael Glaesemann
test=> select '4 months'::interval / 5;
?column?
---------------
1 mon -6 days
(1 row)
after:
test=> select '4 months'::interval / 5;
?column?
----------
24 days
(1 row)
The problem was the use of rint() to round, and then find the remainder,
causing the negative values.
for circle(polygon), which was missing; remove bogus entry for
point(lseg, lseg), which does not exist, and the documentation seemed to
describe lseg_interpt, which we already document as an operator not a
function. Also remove entry for box_intersect, which likewise is
preferentially used via the operator #.
is applied last, after other constraints such as name patterns. This
is useful first because the pg_foo_is_visible() functions are relatively
expensive, and second because it minimizes the prospects for race
conditions. The change is fragile though since it makes unwarranted
assumptions about planner behavior, ie, that WHERE clauses will be
executed in the original order if there's not reason to change it.
This should fix ... or at least hide ... an intermittent failure in the
prepared_xacts regression test, while we think about what else to do.
checked that the pointer is actually word-aligned. Casting a non-aligned
pointer to int32* is technically illegal per the C spec, and some recent
versions of gcc actually generate bad code for the memset() when given
such a pointer. Per report from Andrew Morrow.
port number, and use a default value for it that is dependent on the
configuration-time DEF_PGPORT. Should make the world safe for running
parallel 'make check' in different branches. Back-patch as far as 7.4
so that this actually is useful.
output targetlist of the Unique or HashAgg plan. This code was OK when
written, but subsequent changes to use "physical tlists" where possible
had broken it: given an input subplan that has extra variables added to
avoid a projection step, it would copy those extra variables into the
upper tlist, which is pointless since a projection has to happen anyway.
I have seen this case in CVS tip due to new "physical tlist" optimization
for subqueries. I believe it probably can't happen in existing releases,
but the check is not going to hurt anything, so backpatch to 8.0 just
in case.
cases: we can't just consider whether the subquery's output is unique on its
own terms, we have to check whether the set of output columns we are going to
use will be unique. Per complaint from Luca Pireddu and test case from
Michael Fuhr.
requiring superuserness always, allow an owner to reassign ownership
to any role he is a member of, if that role would have the right to
create a similar object. These three requirements essentially state
that the would-be alterer has enough privilege to DROP the existing
object and then re-CREATE it as the new role; so we might as well
let him do it in one step. The ALTER TABLESPACE case is a bit
squirrely, but the whole concept of non-superuser tablespace owners
is pretty dubious anyway. Stephen Frost, code review by Tom Lane.
I wrote:
> So either we code up some intelligence to put the "C" in the right
> position or we have to pass down "A B" and "D" separately from the
> main makefile.
The following patch might just do the former. Please try it out.
Peter E.