summaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Collapse)Author
2005-07-22Fix AT TIME ZONE for timestamps without time zones:Bruce Momjian
test=> select ('2005-07-20 00:00:00'::timestamp without time zone) at time zone 'Europe/Paris'; timezone ------------------------ 2005-07-19 22:00:00-04 Udpate documentation.
2005-07-22Fix insufficient check for overflow in tm2abstime(), per report from jw.Tom Lane
2005-07-22Fix compare_fuzzy_path_costs() to behave a bit more sanely. The originalTom Lane
coding would ignore startup cost differences of less than 1% of the estimated total cost; which was OK for normal planning but highly not OK if a very small LIMIT was applied afterwards, so that startup cost becomes the name of the game. Instead, compare startup and total costs fuzzily but independently. This changes the plan selected for two queries in the regression tests; adjust expected-output files for resulting changes in row order. Per reports from Dawid Kuroczko and Sam Mason.
2005-07-22More removal of unneeded parentheses.Bruce Momjian
2005-07-22More spacing adjustmentsBruce Momjian
2005-07-22Update date/time comments.Bruce Momjian
2005-07-22More minor spacing improvements.Bruce Momjian
2005-07-22Code spacing improvement, particularly *tm spacing.Bruce Momjian
2005-07-21More comment update of time macros.Bruce Momjian
2005-07-21Update DAYS_PER_MONTH comment.Bruce Momjian
Add SECS_PER_YEAR and MINS_PER_HOUR macros.
2005-07-21Add comment about void* use in MemSet.Bruce Momjian
2005-07-21Fix integer timestamp build for macro changes.Bruce Momjian
2005-07-21Add comment marking non-exact time conversion macros.Bruce Momjian
2005-07-21Remove unnecessary parentheses in assignments.Bruce Momjian
Add spaces where needed. Reference time interval variables as tinterval.
2005-07-21Add time/date macros for code clarity:Bruce Momjian
#define DAYS_PER_YEAR 365.25 #define MONTHS_PER_YEAR 12 #define DAYS_PER_MONTH 30 #define HOURS_PER_DAY 24
2005-07-20Update catalog version for INTERVAL day addition.Bruce Momjian
2005-07-20Add 'day' field to INTERVAL so 1 day interval can be distinguished fromBruce Momjian
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
2005-07-20Fix interval division and multiplication, before:Bruce Momjian
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.
2005-07-18\pset numericsep -> numericlocale.Bruce Momjian
2005-07-18Fix len so decimal length is only added when a period appears in the output.Bruce Momjian
2005-07-18Avoid use of E'', and thereby creating an unnecessary version-dependency,Tom Lane
by using LIKE...ESCAPE instead. Per suggestion by andrew@supernews.
2005-07-18Avoid need for E'' construct by using regexp instead of LIKE. MoreTom Lane
readable, and more like the other places in this file.
2005-07-18Fix numiericsep length computations.Bruce Momjian
Eugen Nedelcu
2005-07-18Adjust psql describe queries so that any pg_foo_is_visible() conditionTom Lane
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.
2005-07-18MemSet() must not cast its pointer argument to int32* until after it hasTom Lane
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.
2005-07-17Make pg_regress accept a command-line option for the temporary installation'sTom Lane
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.
2005-07-15Fix create_unique_plan() so it doesn't generate useless entries in theTom Lane
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.
2005-07-15Check for out-of-range varoattno in deparse_context_for_subplan.Tom Lane
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.
2005-07-15Fix overenthusiastic optimization of 'x IN (SELECT DISTINCT ...)' and relatedTom Lane
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.
2005-07-14Adjust permissions checking for ALTER OWNER commands: instead ofTom Lane
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.
2005-07-14Enable multi-byte thousands_sep and decimal_point for numericsep.Bruce Momjian
2005-07-14Make better thousands_sep default based on decimal marker value.Bruce Momjian
2005-07-14Change numericsep to a boolean, and make it locale-aware.Bruce Momjian
2005-07-14Add numeric separator support for latex and troff output methods.Bruce Momjian
2005-07-14barebones variable name -> tuples_only, for consistency.Bruce Momjian
2005-07-14Fix malloc length for new numeric separator patch.Bruce Momjian
Centralize malloc into function.
2005-07-14Integrate autovacuum functionality into the backend. There's still aTom Lane
few loose ends to be dealt with, but it seems to work. Alvaro Herrera, based on the contrib code by Matthew O'Connor.
2005-07-13Fix a couple of bogus comments, per Alvaro.Tom Lane
2005-07-13Remove extraneous space after -L ... it confuses SHLIB_LINK filter -LTom Lane
hack.
2005-07-13Fix unwanted side-effects of recent SHLIB_LINK -L patch on existingTom Lane
hacking of SHLIB_LINK for HPUX.
2005-07-13Fix #elif spacing too.Bruce Momjian
2005-07-13Fix libpq memory leak during PQreset() --- closePGconn() was notTom Lane
freeing all transient state of the PGconn object.
2005-07-13Fix pgindent to not have blank line before #else in variable definitionBruce Momjian
section of a function.
2005-07-13Add backslashes to parentheses in awk regex because if not, they areBruce Momjian
treated as regex groups.
2005-07-13Move -L flag around for shared builds:Bruce Momjian
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.
2005-07-12Hack around the discrepancy between default library search paths forTom Lane
gcc and for HP's ld on HPUX. There may be better ways to do this, but this seems to work for me...
2005-07-12Fix plperl crash with list value return for an array result type.Tom Lane
Reported by Michael Fuhr, fixed by Andrew Dunstan.
2005-07-12Improve comments for AdjustIntervalForTypmod.Bruce Momjian
Blank line adjustments.
2005-07-12Change 5e0 to 5.0, for consistency.Bruce Momjian
2005-07-12Fix plperl to do recursion safely, and fix a problem with array results.Tom Lane
Add suitable regression tests. Andrew Dunstan