OSDN Git Service
Tom Lane [Mon, 5 Jun 2006 02:49:58 +0000 (02:49 +0000)]
Add a GUC parameter seq_page_cost, and use that everywhere we formerly
assumed that a sequential page fetch has cost 1.0. This patch doesn't
in itself change the system's behavior at all, but it opens the door to
people adopting other units of measurement for EXPLAIN costs. Also, if
we ever decide it's worth inventing per-tablespace access cost settings,
this change provides a workable intellectual framework for that.
Bruce Momjian [Sun, 4 Jun 2006 04:35:55 +0000 (04:35 +0000)]
Fix psql so \r is separate in the history, rather than at the end of
the query.
Bruce Momjian [Sun, 4 Jun 2006 02:11:04 +0000 (02:11 +0000)]
Update:
< * %Remove behavior of postmaster -o
> * %Make postmater and postgres options distinct so the postmaster -o
> option is no longer needed
Bruce Momjian [Sun, 4 Jun 2006 01:33:39 +0000 (01:33 +0000)]
Update:
< o Allow COPY to output from views
> o Allow COPY to output from SELECT
570c570
< Another idea would be to allow actual SELECT statements in a COPY.
> COPY should also be able to output views.
Bruce Momjian [Sun, 4 Jun 2006 00:17:43 +0000 (00:17 +0000)]
Update GUI FAQ.
Robert Treat
Bruce Momjian [Sun, 4 Jun 2006 00:13:43 +0000 (00:13 +0000)]
Update GUI tools URL.
Robert Treat
Tom Lane [Sat, 3 Jun 2006 17:36:10 +0000 (17:36 +0000)]
Don't choke during startup if the environment offers an invalid value
for LC_MESSAGES; instead, just press forward, leaving the effective setting
at 'C'. There is not any very good reason to complain when we are going
to replace the value soon with whatever postgresql.conf says. This change
should solve the occasionally-reported problem of initdb failing with
'failed to initialize lc_messages'; the current theory is that that is
a reflection of either wrong LANG/LC_MESSAGES or completely broken locale
support.
Tom Lane [Sat, 3 Jun 2006 16:48:59 +0000 (16:48 +0000)]
Fix copy-and-pasteo in Russian translation: message complaining about
HAVE_INT64_TIMESTAMP was mentioning PG_CONTROL_VERSION instead.
Victor Snezhko
Bruce Momjian [Sat, 3 Jun 2006 04:00:01 +0000 (04:00 +0000)]
Record location of partial patch :
> * Allow WAL information to recover corrupted pg_controldata
>
> See partially completed patch and additional work required at
> http://archives.postgresql.org/pgsql-patches/2006-06/msg00025.php.
>
Tom Lane [Sat, 3 Jun 2006 02:53:04 +0000 (02:53 +0000)]
Mention pg_encoding_to_char in entry for pg_database.encoding.
Per Larry Rosenman.
Bruce Momjian [Sat, 3 Jun 2006 02:34:35 +0000 (02:34 +0000)]
Patch reverted, not done:
> * Allow WAL information to recover corrupted pg_controldata
Bruce Momjian [Sat, 3 Jun 2006 02:19:24 +0000 (02:19 +0000)]
Remove pg_resetxlog -r flag, feature has problems referenced here:
http://archives.postgresql.org/pgsql-hackers/2006-05/msg00002.php
Teodor Sigaev [Fri, 2 Jun 2006 18:03:06 +0000 (18:03 +0000)]
Fix wrong NOTICE/ERROR levels
Teodor Sigaev [Fri, 2 Jun 2006 17:55:40 +0000 (17:55 +0000)]
Distinguish between stop-word recognized in thesaurus_lexize()
Teodor Sigaev [Fri, 2 Jun 2006 15:35:42 +0000 (15:35 +0000)]
Add more strict check of stop and non-recognized words,
allow only recognized words in thezaurus configuration file.
Tom Lane [Thu, 1 Jun 2006 02:39:59 +0000 (02:39 +0000)]
Got tired of waiting for spoonbill's compiler to get fixed. Let's
see if using an intermediate variable avoids the gcc bug.
Tom Lane [Thu, 1 Jun 2006 01:28:00 +0000 (01:28 +0000)]
Respond to Jeremy Drake's original gripe that \copy needs to recognize
E'...' syntax for strings in order to track the backend.
Tom Lane [Thu, 1 Jun 2006 00:15:36 +0000 (00:15 +0000)]
Fix up hack to suppress escape_string_warning so that it actually works
and there's only one place that's a kluge, ie, appendStringLiteralConn.
Note that pg_dump itself doesn't use appendStringLiteralConn, so its
behavior is not affected; only the other utility programs care.
Tom Lane [Wed, 31 May 2006 22:34:35 +0000 (22:34 +0000)]
Fix example of how to escape data in psql backslash commands.
Tom Lane [Wed, 31 May 2006 22:11:44 +0000 (22:11 +0000)]
Fix seriously broken patch for psql '' ... per its comment, emit() is
NOT the thing to use here.
Tom Lane [Wed, 31 May 2006 20:58:09 +0000 (20:58 +0000)]
Make PG_MODULE_MAGIC required in shared libraries that are loaded into
the server. Per discussion, there seems no point in a waiting period
before making this required.
Teodor Sigaev [Wed, 31 May 2006 14:53:41 +0000 (14:53 +0000)]
fix comparison with SPI_processed
Teodor Sigaev [Wed, 31 May 2006 14:05:31 +0000 (14:05 +0000)]
Add thesaurus dictionary which can replace N>0 lexemes by M>0 lexemes.
It required some changes in lexize algorithm, but interface with
dictionaries stays compatible with old dictionaries.
Funded by Georgia Public Library Service and LibLime, Inc.
Bruce Momjian [Wed, 31 May 2006 11:47:20 +0000 (11:47 +0000)]
Recommend '' for literal ', rather than \', in psql documentation.
Bruce Momjian [Wed, 31 May 2006 11:35:17 +0000 (11:35 +0000)]
Support '' for literal ' in psql single-quote strings, documentation update.
Bruce Momjian [Wed, 31 May 2006 11:02:42 +0000 (11:02 +0000)]
Escape processing patch:
o turns off escape_string_warning in pg_dumpall.c
o optionally use E'' for \password (undocumented option?)
o honor standard_conforming-strings for \copy (but not
support literal E'' strings)
o optionally use E'' for \d commands
o turn off escape_string_warning for createdb, createuser,
droplang
Bruce Momjian [Wed, 31 May 2006 10:24:29 +0000 (10:24 +0000)]
Update cvs command example to show diff -rBASE.
Michael Meskes [Wed, 31 May 2006 08:12:48 +0000 (08:12 +0000)]
Somehow a ";" got lost which changed the logic. This btw is the first fix resulting from SoC.
Tom Lane [Tue, 30 May 2006 22:12:16 +0000 (22:12 +0000)]
Magic blocks don't do us any good unless we use 'em ... so install one
in every shared library.
Tom Lane [Tue, 30 May 2006 21:34:15 +0000 (21:34 +0000)]
Un-DOS-ify newly added files.
Tom Lane [Tue, 30 May 2006 21:21:30 +0000 (21:21 +0000)]
Code review for magic-block patch. Remove separate header file pgmagic.h,
as this seems only likely to create headaches for module developers. Put
the macro in the pre-existing fmgr.h file instead. Avoid being too cute
about how many fields we can cram into a word, and avoid trying to fetch
from a library we've already unlinked.
Along the way, it occurred to me that the magic block really ought to be
'const' so it can be stored in the program text area. Do the same for
the existing data blocks for PG_FUNCTION_INFO_V1 functions.
Tom Lane [Tue, 30 May 2006 19:24:25 +0000 (19:24 +0000)]
Code review for EXPLAIN patch. Fix some typos, make it behave sanely
across multiple loops, get rid of the shaky assumption that exactly one
tuple is returned per node iteration.
Tom Lane [Tue, 30 May 2006 17:08:14 +0000 (17:08 +0000)]
PostmasterIsAlive test really ought to be in the inner loop for safety.
Tom Lane [Tue, 30 May 2006 15:57:56 +0000 (15:57 +0000)]
Remove pqsignalinquire(), which is unused and has portability issues.
Tom Lane [Tue, 30 May 2006 15:48:20 +0000 (15:48 +0000)]
Update ppport.h to not cause warnings with newest Perl versions.
This is just the minimal necessary change; we might want to adopt
later PPPort output instead.
Bruce Momjian [Tue, 30 May 2006 14:09:32 +0000 (14:09 +0000)]
Add pgmagic header block to store compile-time constants:
It now only checks four things:
Major version number (7.4 or 8.1 for example)
NAMEDATALEN
FUNC_MAX_ARGS
INDEX_MAX_KEYS
The three constants were chosen because:
1. We document them in the config page in the docs
2. We mark them as changable in pg_config_manual.h
3. Changing any of these will break some of the more popular modules:
FUNC_MAX_ARGS changes fmgr interface, every module uses this NAMEDATALEN
changes syscache interface, every PL as well as tsearch uses this
INDEX_MAX_KEYS breaks tsearch and anything using GiST.
Martijn van Oosterhout
Bruce Momjian [Tue, 30 May 2006 14:01:58 +0000 (14:01 +0000)]
Make EXPLAIN sampling smarter, to avoid excessive sampling delay.
Martijn van Oosterhout
Tom Lane [Tue, 30 May 2006 13:58:49 +0000 (13:58 +0000)]
Clarify the HINT for 'checkpoint request failed', per recent complaint
demonstrating that its intent wasn't obvious.
Bruce Momjian [Tue, 30 May 2006 13:52:25 +0000 (13:52 +0000)]
Emit warnings for unknown configure options.
Martijn van Oosterhout
Bruce Momjian [Tue, 30 May 2006 13:40:56 +0000 (13:40 +0000)]
Revert patch, needs more work:
---------------------------------------------------------------------------
Add dynamic record inspection to PL/PgSQL, useful for generic triggers:
tval2 := r.(cname);
or
columns := r.(*);
Titus von Boxberg
Bruce Momjian [Tue, 30 May 2006 13:36:30 +0000 (13:36 +0000)]
Move conversion dependency patch to the proper branch, out of 8.1.X,
into HEAD.
Bruce Momjian [Tue, 30 May 2006 13:30:49 +0000 (13:30 +0000)]
Prevent multiple archivers from starting. Backpatch to 8.1.X.
Simon Riggs
Bruce Momjian [Tue, 30 May 2006 13:25:57 +0000 (13:25 +0000)]
Add /contrib/adminpack to contrib/Makefile, do case-folding change.
Bruce Momjian [Tue, 30 May 2006 13:04:59 +0000 (13:04 +0000)]
Fix printf mask for SizeVfdCache
Qingqing Zhou
Bruce Momjian [Tue, 30 May 2006 12:56:45 +0000 (12:56 +0000)]
Re-defines SHA2 symbols so that they would not conflict with certain
versions of OpenSSL. If your OpenSSL does not contain SHA2, then there
should be no conflict. But ofcourse, if someone upgrades OpenSSL,
server starts crashing.
Backpatched to 8.1.X.
Marko Kreen
Bruce Momjian [Tue, 30 May 2006 12:43:28 +0000 (12:43 +0000)]
Add "inline" compile fix for MSVC/BCC:
#define inline __inline
Backpatch to 8.1.X.
Hiroshi Saito
Bruce Momjian [Tue, 30 May 2006 12:27:39 +0000 (12:27 +0000)]
Re-add btree_gist description.
Bruce Momjian [Tue, 30 May 2006 12:07:31 +0000 (12:07 +0000)]
Add Pgadmin administration functions to /contrib/adminpack.
Dave Page
Bruce Momjian [Tue, 30 May 2006 12:03:13 +0000 (12:03 +0000)]
Add dynamic record inspection to PL/PgSQL, useful for generic triggers:
tval2 := r.(cname);
or
columns := r.(*);
Titus von Boxberg
Bruce Momjian [Tue, 30 May 2006 11:58:05 +0000 (11:58 +0000)]
Back out patch, wrong previous commit message.
Bruce Momjian [Tue, 30 May 2006 11:54:51 +0000 (11:54 +0000)]
Add regexp_replace() to string functions section.
Joachim Wieland
Bruce Momjian [Tue, 30 May 2006 11:40:21 +0000 (11:40 +0000)]
Update PL documentation:
An article at WebProNews quoted from the PG docs as to the merits of
stored procedures. I have added a bit more material on their merits,
as well as making a few changes to improve the introductions to
PL/Perl and PL/Tcl.
Chris Browne
Bruce Momjian [Tue, 30 May 2006 10:29:18 +0000 (10:29 +0000)]
Update Japanese FAQ.
J.Kuwamura
Bruce Momjian [Tue, 30 May 2006 10:21:12 +0000 (10:21 +0000)]
Add item:
> * Consider GnuTLS if OpenSSL license becomes a problem
>
> See http://archives.postgresql.org/pgsql-patches/2006-05/msg00040.php.
Tom Lane [Tue, 30 May 2006 05:22:59 +0000 (05:22 +0000)]
Fix ancient misdescription of namegt/namege in comment. Greg Stark
Bruce Momjian [Tue, 30 May 2006 02:35:39 +0000 (02:35 +0000)]
Patch reverted because of random buildfarm failures:
---------------------------------------------------------------------------
Delay write of pg_stats file to once every five minutes, during
shutdown, or when requested by a backend:
It changes so the file is only written once every 5 minutes (changeable
of course, I just picked something) instead of once every half second.
It's still written when the stats collector shuts down, just as before.
And it is now also written on backend request. A backend requests a
rewrite by simply sending a special stats message. It operates on the
assumption that the backends aren't actually going to read the
statistics file very often, compared to how frequent it's written today.
Magnus Hagander
Bruce Momjian [Mon, 29 May 2006 23:29:38 +0000 (23:29 +0000)]
Add:
> o Allow timezone names in SQL strings, '2006-05-24 21:11
> Americas/New_York'::timestamptz
Bruce Momjian [Mon, 29 May 2006 19:52:46 +0000 (19:52 +0000)]
Add PQclear() calls, for completeness (exits shortly anyway).
Andrew Dunstan [Mon, 29 May 2006 13:51:23 +0000 (13:51 +0000)]
Make plperl's $_TD trigger data a global rather than a lexical variable,
with a fresh local value for each invocation, to avoid unexpected sharing
violations. Per recent -hackers discussion.
Teodor Sigaev [Mon, 29 May 2006 12:50:06 +0000 (12:50 +0000)]
Som improve page split in multicolumn GiST index.
If user picksplit on n-th column generate equals
left and right unions then it calls picksplit on n+1-th
column.
Teodor Sigaev [Mon, 29 May 2006 08:39:44 +0000 (08:39 +0000)]
Correct cheking in findParents(). i
From Andreas Seltenreich <andreas+pg@gate450.dyndns.org>
Tom Lane [Sun, 28 May 2006 22:42:05 +0000 (22:42 +0000)]
enlargePQExpBuffer, alone among the functions exported by pqexpbuffer.h,
wasn't exported by exports.txt. Ooops. Per buildfarm results.
Tom Lane [Sun, 28 May 2006 21:13:54 +0000 (21:13 +0000)]
Fix up pg_dump to do string escaping fully correctly for client encoding
and standard_conforming_strings; likewise for the other client programs
that need it. As per previous discussion, a pg_dump dump now conforms
to the standard_conforming_strings setting of the source database.
We don't use E'' syntax in the dump, thereby improving portability of
the SQL. I added a SET escape_strings_warning = off command to keep
the dumps from getting a lot of back-chatter from that.
Alvaro Herrera [Sun, 28 May 2006 17:23:29 +0000 (17:23 +0000)]
Don't call PQclear until the struct is really no longer going to be used.
Per Coverity bug #304. Thanks to Martijn van Oosterhout for reporting it.
Zero out the pointer fields of PGresult so that these mistakes are more
easily catched, per discussion.
Andrew Dunstan [Sun, 28 May 2006 03:12:00 +0000 (03:12 +0000)]
fix typo
Andrew Dunstan [Sun, 28 May 2006 03:03:17 +0000 (03:03 +0000)]
TG_table_name and TG_table_schema for plpgsql, plus docs and regression.
Alvaro Herrera [Sun, 28 May 2006 02:27:08 +0000 (02:27 +0000)]
Remove traces of otherwise unused RELKIND_SPECIAL symbol. Leave the psql bits
in place though, so that it plays nicely with older servers.
Per discussion.
Andrew Dunstan [Sat, 27 May 2006 20:24:16 +0000 (20:24 +0000)]
TG_table_name and TG_table_schema for pl/tcl, plus regression test and docs.
Tom Lane [Sat, 27 May 2006 19:45:52 +0000 (19:45 +0000)]
Revert ill-considered change to plpgsql: it should not rely on the
current setting of standard_conforming_strings to decide how to quote
strings that will be used later. There is much more to do here but
this particular change breaks the build on Windows, so fix it now.
Tom Lane [Sat, 27 May 2006 18:07:06 +0000 (18:07 +0000)]
Fix initdb to properly escape quotes and backslashes in the supplied
superuser password, and also in the paths of the various files it issues
SQL COPY commands for. Per bug #2424.
Tom Lane [Sat, 27 May 2006 17:38:46 +0000 (17:38 +0000)]
Re-introduce the yylex filter function formerly used to support UNION
JOIN, which I removed in a recent fit of over-optimism that we wouldn't
have any future use for it. Now it's needed to support disambiguating
WITH CHECK OPTION from WITH TIME ZONE. As proof of concept, add stub
grammar productions for WITH CHECK OPTION.
Andrew Dunstan [Sat, 27 May 2006 12:39:11 +0000 (12:39 +0000)]
Looks like the new plpython regression test fails on older pythons. See if this works.
Bruce Momjian [Fri, 26 May 2006 23:48:54 +0000 (23:48 +0000)]
Use E'' strings internally only when standard_conforming_strings =
'off'. This allows pg_dump output with standard_conforming_strings =
'on' to generate proper strings that can be loaded into other databases
without the backslash doubling we typically do. I have added the
dumping of the standard_conforming_strings value to pg_dump.
I also added standard backslash handling for plpgsql.
Tom Lane [Fri, 26 May 2006 22:50:02 +0000 (22:50 +0000)]
Further hacking on performance of COPY OUT. It seems that fwrite()'s
per-call overhead is quite significant, at least on Linux: whatever
it's doing is more than just shoving the bytes into a buffer. Buffering
the data so we can call fwrite() just once per row seems to be a win.
Tom Lane [Fri, 26 May 2006 19:51:29 +0000 (19:51 +0000)]
Support binary COPY through psql. Also improve detection of write errors
during COPY OUT. Andreas Pflug, some editorialization by moi.
Bruce Momjian [Fri, 26 May 2006 19:48:32 +0000 (19:48 +0000)]
Update AIX FAQ.
Chris Browne
Andrew Dunstan [Fri, 26 May 2006 19:23:09 +0000 (19:23 +0000)]
Add table_name and table_schema to plpython trigger data, plus docs and regression test.
Andrew Dunstan [Fri, 26 May 2006 17:34:16 +0000 (17:34 +0000)]
Add table_name and table_schema to plperl trigger data. relname is
kept but now deprecated. Patch from Adam Sjøgren. Add regression test to
show plperl trigger data (Andrew).
TBD: apply similar changes to plpgsql, plpython and pltcl.
Teodor Sigaev [Fri, 26 May 2006 08:01:17 +0000 (08:01 +0000)]
Fix findParents() in case of multiple levels to find.
By Andreas Seltenreich <andreas+pg@gate450.dyndns.org>
Tom Lane [Thu, 25 May 2006 18:42:17 +0000 (18:42 +0000)]
Reduce per-character overhead in COPY OUT by combining calls to
CopySendData.
Tom Lane [Wed, 24 May 2006 21:20:11 +0000 (21:20 +0000)]
Fix pg_restore to process BLOB COMMENT entries correctly; they aren't
really tables and shouldn't get DISABLE TRIGGER processing. Per bug
#2452 from Robert Treat.
Bruce Momjian [Wed, 24 May 2006 18:12:38 +0000 (18:12 +0000)]
Remove pg_attribute detail, add URL
< pg_attribute.attislocal has to be set to 'false' for ADD, and
< pg_attribute.attinhcount adjusted appropriately
> See http://archives.postgresql.org/pgsql-hackers/2006-05/msg00988.php.
Teodor Sigaev [Wed, 24 May 2006 11:01:39 +0000 (11:01 +0000)]
* Add support NULL to GiST.
* some refactoring and simplify code int gistutil.c and gist.c
* now in some cases it can be called used-defined
picksplit method for non-first column in index, but here
is a place to do more.
* small fix of docs related to support NULL.
Bruce Momjian [Tue, 23 May 2006 22:14:27 +0000 (22:14 +0000)]
Remove trailing blank line from exports.txt.
Bruce Momjian [Tue, 23 May 2006 22:13:19 +0000 (22:13 +0000)]
Add PQisthreadsafe() to libpq, to allow library applications to query
the thread-safety status of the library.
Tom Lane [Tue, 23 May 2006 21:37:59 +0000 (21:37 +0000)]
Tweak writetup_heap/readtup_heap to avoid storing the tuple identity
and transaction visibility fields of tuples being sorted. These are
always uninteresting in a tuple being sorted (if the fields were actually
selected, they'd have been pulled out into user columns beforehand).
This saves about 24 bytes per row being sorted, which is a useful savings
for any but the widest of sort rows. Per recent discussion.
Bruce Momjian [Tue, 23 May 2006 20:59:29 +0000 (20:59 +0000)]
Update text:
> This allows tables to be added/removed from an inheritance
> hierarchy. This is particularly useful for table partitioning.
Bruce Momjian [Tue, 23 May 2006 20:57:53 +0000 (20:57 +0000)]
Add:
> o Add ALTER TABLE tab ADD/DROP INHERITS parent
>
> pg_attribute.attislocal has to be set to 'false' for ADD, and
> pg_attribute.attinhcount adjusted appropriately
>
Bruce Momjian [Tue, 23 May 2006 20:20:52 +0000 (20:20 +0000)]
Rename in release notes: Mac -> OS/X, Intel to x86:
Fix for OS/X Bonjour on x86 systems (Ashley Clark)
Bruce Momjian [Tue, 23 May 2006 19:28:45 +0000 (19:28 +0000)]
Avoid duplicate definition of LOCALEDIR in pg_config.h, already defined
in port/pg_config_paths.h.
Bruce Momjian [Tue, 23 May 2006 15:51:07 +0000 (15:51 +0000)]
New wording, "What is the upgrade process for PostgreSQL?"
Bruce Momjian [Tue, 23 May 2006 15:47:43 +0000 (15:47 +0000)]
Update heading for upgrades.
Bruce Momjian [Tue, 23 May 2006 15:22:20 +0000 (15:22 +0000)]
Add mention that everyone should upgrade to minor releases.
Tom Lane [Tue, 23 May 2006 15:21:52 +0000 (15:21 +0000)]
Remove CXT_printf/CXT1_printf macros. If anyone had found them to be of
any use in the past many years, we'd have made some effort to include
them in all executor node types; but in fact they were only in
nodeAppend.c and nodeIndexscan.c, up until I copied nodeIndexscan.c's
occurrence into the new bitmap node types. Remove some other unused
macros in execdebug.h, too. Some day the whole header probably ought to
go away in favor of better-designed facilities.
Bruce Momjian [Mon, 22 May 2006 20:39:23 +0000 (20:39 +0000)]
Make "trigger" section:
> * Referential Integrity
>
> o Add MATCH PARTIAL referential integrity
> o Change foreign key constraint for array -> element to mean element
> in array?
> o Enforce referential integrity for system tables
>
>
< Referential Integrity
< =====================
<
< * Add MATCH PARTIAL referential integrity
> Triggers
> ========
< * Change foreign key constraint for array -> element to mean element
< in array?
801d804
< * Enforce referential integrity for system tables
Bruce Momjian [Mon, 22 May 2006 14:12:55 +0000 (14:12 +0000)]
Update Japanese FAQ.
J.Kuwamura
Bruce Momjian [Mon, 22 May 2006 14:08:06 +0000 (14:08 +0000)]
Change \; to ; in RULE, \; unnecessary.
Peter Eisentraut [Mon, 22 May 2006 11:21:54 +0000 (11:21 +0000)]
Add strerror to pg_dump error messages where missing.
Tom Lane [Sun, 21 May 2006 21:49:22 +0000 (21:49 +0000)]
Update release notes for upcoming releases.
Bruce Momjian [Sun, 21 May 2006 20:29:16 +0000 (20:29 +0000)]
Remove mention of pg_upgrade in release checklist.