git.postgresql.org Git - postgresql.git/log
On Win32, use loop to create pg_dump temporary tar file in the current
directory, not in device root, for permission reasons.
Backpatch to 8.1.X.
Done:
> o -Add PQescapeIdentifier()
Add PQescapeIdentifier() to libpq
Christopher Kings-Lynne
Fix blank line.
Add comment about the use of pg_config_paths.h.
Tom Lane [2006年6月26日 17:24:41 +0000 (17:24 +0000)]
Change the row constructor syntax (ROW(...)) so that list elements foo.*
will be expanded to a list of their member fields, rather than creating
a nested rowtype field as formerly. (The old behavior is still available
by omitting '.*'.) This syntax is not allowed by the SQL spec AFAICS,
so changing its behavior doesn't violate the spec. The new behavior is
substantially more useful since it allows, for example, triggers to check
for data changes with 'if row(new.*) is distinct from row(old.*)'. Per
my recent proposal.
Added missing braces to prevent a segfault after usage of an undeclared cursor.
Use Unix newlines, instead of DOS ones.
Use Unix line endings instead of DOS ones, per Magnus.
Update include files to Unix newline format, per report from Magnus.
Update comment description of geo routines and move comment to more
relevant location.
Added some more coverity report patches send in by Joachim Wieland <joe@mcknight.de>.
Update my info:
> * Bruce is Bruce Momjian <bruce@momjian.us> of EnterpriseDB
Tom Lane [2006年6月25日 18:29:49 +0000 (18:29 +0000)]
Tweak dynahash.c to avoid wasting memory space in non-shared hash tables.
palloc() will normally round allocation requests up to the next power of 2,
so make dynahash choose allocation sizes that are as close to a power of 2
as possible.
Back-patch to 8.1 --- the problem exists further back, but a much larger
patch would be needed and it doesn't seem worth taking any risks.
Add:
< * Reuse index tuples that point to rows that are not visible to anyone?
> * Reuse index tuples that point to heap tuples that are not visible to
> anyone?
Moved some free() calls that coverity correctly complains about.
Our version of getopt_long does not set optarg upon detecting an error, as
opposed to what other versions apparently do, so it's not safe to print an
error message. Besides, getopt_long itself already did, so it's redundant
anyway.
Remove individual user copyright because the code is contributed to
PGDG:
> Yes. In fact the copyright belongs to credativ GmbH the company that
> paid Carsten for his work. As you may or may not know I'm the CEO of
> that company and can assure you that his work was contributed to the
> PostgreSQL project.
Fix GEVHDRSZ for Win32.
Magnus Hagander
Fix Win32/Cygwin problems:
After updating to the latest cvs, and also building most of the addons
(like PLs), the following patch is neededf for win32 + Visual C++.
* Switch to use the new win32 semaphore code
* Rename win32_open to pgwin32_open. win32_open collides with symbols
defined in Perl. MingW didn't detect ig, MSVC did. And it's a bit too
generic a name to export globally, imho...
* Python defines some partially broken #pragmas in the headers when
doing a debug build. Workaround.
Magnus Hagander
Update entry:
< * Allow heap reuse of UPDATEd rows if old and new versions are on the
< same heap page?
> * Allow heap reuse of UPDATEd rows if no indexed columns are changed,
> and old and new versions are on the same heap page?
< This is possible for same-page updates because a single index row
< can point to both old and new values.
> While vacuum handles DELETEs fine, updating of non-indexed columns, like
> counters, are difficult for VACUUM to handle efficiently. This method
> is possible for same-page updates because a single index row can be
> used to point to both old and new values.
Add UPDATE entry for row reuse.
>
> * Allow heap reuse of UPDATEd rows if old and new versions are on the
> same heap page?
>
> This is possible for same-page updates because a single index row
> can point to both old and new values.
> http://archives.postgresql.org/pgsql-hackers/2006-06/msg01305.php
Tom Lane [2006年6月24日 14:52:48 +0000 (14:52 +0000)]
Fix re-inclusion of port header file on Windows, per Magnus.
Clarified copyright notice
Tom Lane [2006年6月22日 23:50:35 +0000 (23:50 +0000)]
Remove dllinit.c; it was only needed for long-obsolete Cygwin versions,
and there was some question about its copyright status.
Tom Lane [2006年6月22日 20:42:57 +0000 (20:42 +0000)]
pg_stop_backup was calling XLogArchiveNotify() twice for the newly created
backup history file. Bug introduced by the 8.1 change to make pg_stop_backup
delete older history files. Per report from Masao Fujii.
Tom Lane [2006年6月22日 14:36:12 +0000 (14:36 +0000)]
Standalone backends need pgstat_bestart() too, per Qingqing Zhou.
Tom Lane [2006年6月21日 19:40:31 +0000 (19:40 +0000)]
Move setup_cancel_handler() up near start of psql main(), where the
setup_win32_locks() call formerly was, to ensure that cancelConnLock is
valid when it needs to be. Per Yoshiyuki Asaba.
Tom Lane [2006年6月21日 18:39:42 +0000 (18:39 +0000)]
Remove ancient kluge that kept nodeAgg.c from crashing on UPDATEs involving
aggregates. We just disallowed that, and AFAICS there should be no other
cases where direct (non-aggregated) references to input columns are allowed
in a query with aggregation and no GROUP BY.
Tom Lane [2006年6月21日 18:30:11 +0000 (18:30 +0000)]
Disallow aggregate functions in UPDATE commands (unless within a sub-SELECT).
This is disallowed by the SQL spec because it doesn't have any very sensible
interpretation. Historically Postgres has allowed it but behaved strangely.
As of PG 8.1 a server crash is possible if the MIN/MAX index optimization gets
applied; rather than try to "fix" that, it seems best to just enforce the
spec restriction. Per report from Josh Drake and Alvaro Herrera.
Tom Lane [2006年6月21日 18:09:53 +0000 (18:09 +0000)]
Eliminate a gratuitously different wording of the 'cannot use aggregate function in check constraint' error message.
Joe Conway [2006年6月21日 16:43:11 +0000 (16:43 +0000)]
- During dblink_open, if transaction state was IDLE, force cursor count to
initially be 0. This is needed as a previous ABORT might have wiped out
an automatically opened transaction without maintaining the cursor count.
- Fix regression test expected file for the correct ERROR message, which
we now get given the above bug fix.
Tom Lane [2006年6月21日 16:05:11 +0000 (16:05 +0000)]
Clean up psql variable code a little: eliminate unnecessary tests in
GetVariable() and be consistent about treatment of the list header.
Motivated by noticing strspn() taking an unreasonable percentage of
runtime --- the call removed from GetVariable() was the only one that
could be in a high-usage path ...
Added some more coverity report patches send in by Martijn van Oosterhout <kleptog@svana.org>.
Fixed small typo in changelog
Added fixed from the coverity report send in by Joachim Wieland <joe@mcknight.de>
Added missing error handling in a few functions in ecpglib
Tom Lane [2006年6月20日 22:52:00 +0000 (22:52 +0000)]
Remove redundant gettimeofday() calls to the extent practical without
changing semantics too much. statement_timestamp is now set immediately
upon receipt of a client command message, and the various places that used
to do their own gettimeofday() calls to mark command startup are referenced
to that instead. I have also made stats_command_string use that same
value for pg_stat_activity.query_start for both the command itself and
its eventual replacement by <IDLE> or <idle in transaction>. There was
some debate about that, but no argument that seemed convincing enough to
justify an extra gettimeofday() call.
Tom Lane [2006年6月20日 19:56:52 +0000 (19:56 +0000)]
Split definitions for md5.c out of crypt.h and into their own header
libpq/md5.h, so that there's a clear separation between backend-only
definitions and shared frontend/backend definitions. (Turns out this
is reversing a bad decision from some years ago...) Fix up references
to crypt.h as needed. I looked into moving the code into src/port, but
the headers in src/include/libpq are sufficiently intertwined that it
seems more work than it's worth to do that.
Tom Lane [2006年6月19日 16:13:01 +0000 (16:13 +0000)]
Some editorial work on the documentation of the current-date/time
functions.
Do not use already free'ed errmsg, bug found by Joachim Wieland
<joachim.wieland@credativ.de>
Tom Lane [2006年6月19日 01:51:22 +0000 (01:51 +0000)]
Take the statistics collector out of the loop for monitoring backends'
current commands; instead, store current-status information in shared
memory. This substantially reduces the overhead of stats_command_string
and also ensures that pg_stat_activity is fully up to date at all times.
Per my recent proposal.
Update my email address.
Tom Lane [2006年6月18日 18:30:21 +0000 (18:30 +0000)]
Don't try to call posix_fadvise() unless <fcntl.h> supplies a declaration
for it. Hopefully will fix core dump evidenced by some buildfarm members
since fadvise patch went in. The actual definition of the function is not
ABI-compatible with compiler's default assumption in the absence of any
declaration, so it's clearly unsafe to try to call it without seeing a
declaration.
Tom Lane [2006年6月18日 17:30:48 +0000 (17:30 +0000)]
Fix saveHistory() to not emit bogus complaint during psql exit when using
Darwin's libedit; per my proposal last August. Also, suppress cast-away-
const warnings.
Tom Lane [2006年6月18日 16:21:23 +0000 (16:21 +0000)]
Increase timeout in statement_timeout test from 1 second to 2 seconds.
We have once or twice seen failures suggesting that control didn't get
to the exception block before the timeout elapsed, which is unlikely
but not impossible in a parallel regression test (with a dozen other
backends competing for cycles). This change doesn't completely prevent
the problem of course, but it should reduce the probability enough that
we don't see it anymore. Per buildfarm results.
Merge postmaster and postgres command into just postgres. postmaster
symlink is kept for now for compatibility. To call single-user mode, use
postgres --single.
Tom Lane [2006年6月16日 23:50:48 +0000 (23:50 +0000)]
Fix a couple of obvious problems in DROP IF EXISTS patch.
Tom Lane [2006年6月16日 23:29:27 +0000 (23:29 +0000)]
Code review for SELECT INTO STRICT patch: use saner choices of error
SQLSTATEs, fix some documentation problems.
Tom Lane [2006年6月16日 22:41:45 +0000 (22:41 +0000)]
Clean up after someone's curious idea that it'd be good to strip
leading zeroes from the SQLSTATE codes. They're strings, people,
not numbers.
docs for DROP ... IF EXISTS for the following cases:
language, tablespace, trigger, rule, opclass, function, aggregate. operator, and cast.
Add:
> o Allow PL/python to composite types and result sets
> once buggy assert-enabled versions of python can be detected
>
> http://archives.postgresql.org/pgsql-patches/2006-04/msg00087.php
Add:
>
> * Fix CREATE CAST on DOMAINs
>
> http://archives.postgresql.org/pgsql-hackers/2006-05/msg00072.php
Document issues with non-default tablespaces and pg_dumpall restores.
Backpatch documentation addition to 8.1.X.
Add URL for ISO dates:
> http://archives.postgresql.org/pgsql-bugs/2006-04/msg00248.php
DROP ... IF EXISTS for the following cases:
language, tablespace, trigger, rule, opclass, function, aggregate. operator, and cast.
Add URL for currency type:
> http://archives.postgresql.org/pgsql-general/2005-08/msg01432.php
Add URL for updatable views:
> http://archives.postgresql.org/pgsql-hackers/2006-03/msg00586.php
Add:
> * Consider shrinking expired tuples to just their headers
> http://archives.postgresql.org/pgsql-patches/2006-03/msg00142.php
Tom Lane [2006年6月16日 18:42:24 +0000 (18:42 +0000)]
Fix problems with cached tuple descriptors disappearing while still in use
by creating a reference-count mechanism, similar to what we did a long time
ago for catcache entries. The back branches have an ugly solution involving
lots of extra copies, but this way is more efficient. Reference counting is
only applied to tupdescs that are actually in caches --- there seems no need
to use it for tupdescs that are generated in the executor, since they'll go
away during plan shutdown by virtue of being in the per-query memory context.
Neil Conway and Tom Lane
Add URL to:
* Auto-fill the free space map by scanning the buffer cache or by
checking pages written by the background writer
Add URL for freespace map filling.
>
> http://archives.postgresql.org/pgsql-hackers/2006-02/msg01125.php
>
>
> * Add support for public SYNONYMS
>
> http://archives.postgresql.org/pgsql-hackers/2006-03/msg00519.php
> o Add PL/Python tracebacks
>
> http://archives.postgresql.org/pgsql-patches/2006-02/msg00288.php
Add:
> o Fix problems with RETURN NEXT on tables with
> dropped/added columns after function creation
>
> http://archives.postgresql.org/pgsql-patches/2006-02/msg00165.php
Add URL for:
> * Allow protocol-level BIND parameter values to be logged
>
> http://archives.postgresql.org/pgsql-hackers/2006-02/msg00165.php
Add to locale TODO.detail.
Add URL for ISO date/time syntax:
>
> http://archives.postgresql.org/pgsql-hackers/2006-01/msg00250.php
>
Add LDAP documentation missed in code patch.
Magnus Hagander
Update preload_library magic block wording.
Test for POSIX_FADV_DONTNEED to use posix_fadvise().
Fix:
< get_employee_salary(emp_id AS 12345, tax_year AS 2001)
> get_employee_salary(12345 AS emp_id, 2001 AS tax_year)
Update magic block wording for preloaded libraries.
Use posix_fadvise() to avoid kernel caching of WAL contents on WAL file
close.
ITAGAKI Takahiro
Add STRICT to PL/pgSQL SELECT INTO, so exceptions are thrown if more or
less than one row is returned by the SELECT, for Oracle PL/SQL
compatibility.
Improve SELECT INTO documentation.
Matt Miller
Fix to_ascii() markup error.
Add mention that preload_libraries check the magic block, so
non-PostgreSQL libraries cannot be loaded using this capability.
Update syntax suggestion:
< get_employee_salary(emp_id => 12345, tax_year => 2001)
> get_employee_salary(emp_id AS 12345, tax_year AS 2001)
Move list of supported to_ascii() encodings from footnote to main
description.
Nis Jorgensen
Add:
>
> o Fix memory leak from exceptions
>
> http://archives.postgresql.org/pgsql-performance/2006-06/msg00305.php
Clarify dynamic pl/pgsql item and add URLs. Restructure server-side
section into PL/pgSQL and non-PL/pgSQL sections:
< o Fix PL/pgSQL RENAME to work on variables other than OLD/NEW
< o Allow function parameters to be passed by name,
< get_employee_salary(emp_id => 12345, tax_year => 2001)
< o Add Oracle-style packages
< o Add table function support to pltcl, plpython
< o Add capability to create and call PROCEDURES
< o Allow PL/pgSQL to handle %TYPE arrays, e.g. tab.col%TYPE[]
< o Allow function argument names to be statements from PL/PgSQL
< o Add MOVE to PL/pgSQL
< o Add support for polymorphic arguments and return types to
< languages other than PL/PgSQL
< o Add support for OUT and INOUT parameters to languages other
< than PL/PgSQL
< o Add single-step debugging of PL/PgSQL functions
< o Allow PL/PgSQL to support WITH HOLD cursors
< o Allow PL/PgSQL RETURN to return row or record functions
<
< http://archives.postgresql.org/pgsql-patches/2005-11/msg00045.php
> o PL/pgSQL
> o Fix RENAME to work on variables other than OLD/NEW
> o Allow function parameters to be passed by name,
> get_employee_salary(emp_id => 12345, tax_year => 2001)
> o Add Oracle-style packages
> o Allow handling of %TYPE arrays, e.g. tab.col%TYPE[]
> o Allow listing of record column names, and access to
> record columns via variables, e.g. columns := r.(*),
> tval2 := r.(colname)
>
> http://archives.postgresql.org/pgsql-patches/2005-07/msg00458.php
> http://archives.postgresql.org/pgsql-patches/2006-05/msg00302.php
> http://archives.postgresql.org/pgsql-patches/2006-06/msg00031.php
>
> o Add MOVE
> o Add single-step debugging of functions
> o Add support for WITH HOLD cursors
> o Allow PL/RETURN to return row or record functions
>
> http://archives.postgresql.org/pgsql-patches/2005-11/msg00045.php
>
>
> o Other
> o Add table function support to pltcl, plpython
> o Add support for polymorphic arguments and return types to
> languages other than PL/PgSQL
> o Add capability to create and call PROCEDURES
> o Add support for OUT and INOUT parameters to languages other
> than PL/PgSQL
Add:
> o Allow PL/PgSQL RETURN to return row or record functions
>
> http://archives.postgresql.org/pgsql-patches/2005-11/msg00045.php
Done, removed:
<
< * Consider padding the spinlock structure to have spinlock registers
< on different CPU cache line
<
< http://archives.postgresql.org/pgsql-hackers/2005-10/msg00498.php
Tom Lane [2006年6月15日 02:08:09 +0000 (02:08 +0000)]
Remove the limit on the number of entries allowed in catcaches, and
remove the infrastructure needed to enforce the limit, ie, the global
LRU list of cache entries. On small-to-middling databases this wins
because maintaining the LRU list is a waste of time. On large databases
this wins because it's better to keep more cache entries (we assume
such users can afford to use some more per-backend memory than was
contemplated in the Berkeley-era catcache design). This provides a
noticeable improvement in the speed of psql \d on a 10000-table
database, though it doesn't make it instantaneous.
While at it, use per-catcache settings for the number of hash buckets
per catcache, rather than the former one-size-fits-all value. It's a
bit silly to be using the same number of hash buckets for, eg, pg_am
and pg_attribute. The specific values I used might need some tuning,
but they seem to be in the right ballpark based on CATCACHE_STATS
results from the standard regression tests.
Add to locale TODO.detail.
Remove, done:
<
< * Add support for WIN1253 (Greek) encoding
<
< http://archives.postgresql.org/pgsql-bugs/2005-12/msg00000.php
Add:
>
> * Add support for WIN1253 (Greek) encoding
>
> http://archives.postgresql.org/pgsql-bugs/2005-12/msg00000.php
Add URL to ILIKE encoding fix:
> http://archives.postgresql.org/pgsql-patches/2005-11/msg00173.php
Add:
>
> * Consider increasing internal areas when shared buffers is increased
>
> http://archives.postgresql.org/pgsql-hackers/2005-10/msg01419.php
Already done:
<
< o Properly mark all libpq-exported functions with "PQ"
<
< http://archives.postgresql.org/pgsql-hackers/2005-10/msg00696.php
Done by Peter:
< * Improve the information schema to be more standards-compliant:
<
< http://archives.postgresql.org/pgsql-bugs/2005-10/msg00028.php
Add:
>
> o Properly mark all libpq-exported functions with "PQ"
>
> http://archives.postgresql.org/pgsql-hackers/2005-10/msg00696.php
Add:
>
> * Consider padding the spinlock structure to have spinlock registers
> on different CPU cache line
>
> http://archives.postgresql.org/pgsql-hackers/2005-10/msg00498.php
Add item, not fixed:
>
> * Fix ILIKE and regular expressions to handle case insensitivity
> properly in multibyte encodings
>
> http://archives.postgresql.org/pgsql-bugs/2005-10/msg00001.php
Remove, already in back branches:
<
< o Add new version of PQescapeString() that doesn't double backslashes
< that are part of a client-only multibyte sequence
<
< Single-quote is not a valid byte in any supported client-only
< encoding. This requires using mblen() to determine if the
< backslash is inside or outside a multi-byte sequence.
<
< o Add new version of PQescapeString() that doesn't double
< backslashes when standard_conforming_strings is true and
< non-E strings are used
Done:
> o -Port contrib/xml2
Add information schema item:
> * Improve the information schema to be more standards-compliant:
>
> http://archives.postgresql.org/pgsql-bugs/2005-10/msg00028.php
> * Add URL to more complete multi-byte regression tests
>
> http://archives.postgresql.org/pgsql-hackers/2005-07/msg00272.php
< * Add URL to more complete multi-byte regression tests
<
< http://archives.postgresql.org/pgsql-hackers/2005-07/msg00272.php
Add COPY views patch URL:
> http://archives.postgresql.org/pgsql-patches/2005-09/msg00148.php
Add:
>
> o Add API for 64-bit large object access
>
> http://archives.postgresql.org/pgsql-hackers/2005-09/msg00781.php
Keep TODO.detail until item is done:
< o %Allow pg_dump to use multiple -t and -n switches
> o %Allow pg_dump to use multiple -t and -n switches [pg_dump]
Add URL, remove TODO.detail:
< o %Allow pg_dump to use multiple -t and -n switches [pg_dump]
> o %Allow pg_dump to use multiple -t and -n switches
>
> http://archives.postgresql.org/pgsql-patches/2006-01/msg00190.php
>
This is the main PostgreSQL git repository.
RSS
Atom