Commit Graph

22735 Commits

Author SHA1 Message Date
Bruce Momjian 9ca4c153bf Mention GPL /contrib modules:
>
>   Particularly, move GPL-licensed /contrib/userlock and
>   /contrib/dbmirror/clean_pending.pl.
>
2006-06-07 20:39:10 +00:00
Tom Lane d8364f3f8f Per previous analysis, the most correct notion of SampleOverhead is that
it is just the total time to do INSTR_TIME_SET_CURRENT(), and not any of
the other code involved in InstrStartNode/InstrStopNode.  Even though I
fear we may end up reverting this patch altogether, we may as well have
the most correct version in our CVS archive.
2006-06-07 18:49:03 +00:00
Bruce Momjian e9f6679ce2 Have REINDEX use NOTICE, so it can be suppressed. 2006-06-07 17:20:17 +00:00
Tom Lane ae0c8d09fb Remove "fuzzy comparison" logic in qsort comparison function for
choose_bitmap_and().  It was way too fuzzy --- per comment, it was meant to be
1% relative difference, but was actually coded as 0.01 absolute difference,
thus causing selectivities of say 0.001 and 0.000000000001 to be treated as
equal.  I believe this thinko explains Maxim Boguk's recent complaint.  While
we could change it to a relative test coded like compare_fuzzy_path_costs(),
there's a bigger problem here, which is that any fuzziness at all renders the
comparison function non-transitive, which could confuse qsort() to the point
of delivering completely wrong results.  So forget the whole thing and just
do an exact comparison.
2006-06-07 17:08:07 +00:00
Bruce Momjian ca9d50304f For psql multi-line history, save backslash commands right away, rather
than only if there is already history.
2006-06-07 13:18:37 +00:00
Bruce Momjian 9c351695dc Use INFO-level for reindex messages, rather than NOTICE.
Euler Taveira de Oliveira
2006-06-07 13:13:16 +00:00
Bruce Momjian 6ca917adff Update comment. 2006-06-06 22:41:09 +00:00
Bruce Momjian 62e7ad6603 On Win32, return original patch if GetShortPathName() fails (no short
name, path does not exist), rather than returning nothing.

Backpatch to 8.1.X.
2006-06-06 22:32:19 +00:00
Tom Lane 8a30cc2127 Make the planner estimate costs for nestloop inner indexscans on the basis
that the Mackert-Lohmann formula applies across all the repetitions of the
nestloop, not just each scan independently.  We use the M-L formula to
estimate the number of pages fetched from the index as well as from the table;
that isn't what it was designed for, but it seems reasonably applicable
anyway.  This makes large numbers of repetitions look much cheaper than
before, which accords with many reports we've received of overestimation
of the cost of a nestloop.  Also, change the index access cost model to
charge random_page_cost per index leaf page touched, while explicitly
not counting anything for access to metapage or upper tree pages.  This
may all need tweaking after we get some field experience, but in simple
tests it seems to be giving saner results than before.  The main thing
is to get the infrastructure in place to let cost_index() and amcostestimate
functions take repeated scans into account at all.  Per my recent proposal.

Note: this patch changes pg_proc.h, but I did not force initdb because
the changes are basically cosmetic --- the system does not look into
pg_proc to decide how to call an index amcostestimate function, and
there's no way to call such a function from SQL at all.
2006-06-06 17:59:58 +00:00
Bruce Momjian 05631354f3 Add URL to RESET CONNECTION:
<   notify the protocol when a RESET CONNECTION command is used.
>   notify the protocol when a RESET CONNECTION command is used.  See
>   http://archives.postgresql.org/pgsql-patches/2006-04/msg00192.php
>   for a partial implementation.
2006-06-06 16:27:23 +00:00
Teodor Sigaev 92bcb5abe0 Allow do not lexize words in substitution.
Docs will be submitted some later, now it's at
 http://www.sai.msu.su/~megera/oddmuse/index.cgi/Thesaurus_dictionary
2006-06-06 16:25:55 +00:00
Bruce Momjian 63e464a5e6 Remove ancient AIX structure workaround. 2006-06-06 16:20:11 +00:00
Bruce Momjian ed3b2e696b Have BCC echo output "" using "", rather than \"\" as earlier reported.
Backpatch to 8.1.X.
2006-06-06 16:17:20 +00:00
Bruce Momjian 491a8c27c9 Done:
< * %Make postmater and postgres options distinct so the postmaster -o
> * -Make postmater and postgres options distinct so the postmaster -o
2006-06-06 13:52:21 +00:00
Michael Meskes 0251602fc9 Fixed two more memory leaks in ecpglib.
Synced parser.
2006-06-06 11:31:55 +00:00
Tom Lane ff0ac57db9 Remove extremely old, incomplete, broken example code.
Per my proposal a few days ago.
2006-06-05 21:16:32 +00:00
Tom Lane 7868590c61 While making the seq_page_cost changes, I was struck by the fact that
cost_nonsequential_access() is really totally inappropriate for its only
remaining use, namely estimating I/O costs in cost_sort().  The routine
was designed on the assumption that disk caching might eliminate the need
for some re-reads on a random basis, but there's nothing very random in
that sense about sort's access pattern --- it'll always be picking up the
oldest outputs.  If we had a good fix on the effective cache size we
might consider charging zero for I/O unless the sort temp file size
exceeds it, but that's probably putting much too much faith in the
parameter.  Instead just drop the logic in favor of a fixed compromise
between seq_page_cost and random_page_cost per page of sort I/O.
2006-06-05 20:56:33 +00:00
Bruce Momjian b7af62e4a9 Avoid longjump/vfork warning about line_saved_in_history variable by
making it volatile.
2006-06-05 14:47:38 +00:00
Bruce Momjian a073a70415 Have psql history save \e editor contents to history before query is
executed, like it did for 8.1.X.
2006-06-05 03:55:00 +00:00
Tom Lane e4de635a2b Increase the default value of cpu_index_tuple_cost from 0.001 to 0.005.
This shouldn't affect simple indexscans much, while for bitmap scans that
are touching a lot of index rows, this seems to bring the estimates more
in line with reality.  Per recent discussion.
2006-06-05 03:03:42 +00:00
Tom Lane eed6c9ed7e 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.
2006-06-05 02:49:58 +00:00
Bruce Momjian a837851dc0 Fix psql so \r is separate in the history, rather than at the end of
the query.
2006-06-04 04:35:55 +00:00
Bruce Momjian f6dc20e109 Update:
< * %Remove behavior of postmaster -o
> * %Make postmater and postgres options distinct so the postmaster -o
>   option is no longer needed
2006-06-04 02:11:04 +00:00
Bruce Momjian d7739850e4 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.
2006-06-04 01:33:39 +00:00
Bruce Momjian e5b198066d Update GUI FAQ.
Robert Treat
2006-06-04 00:17:43 +00:00
Bruce Momjian 1309c6f547 Update GUI tools URL.
Robert Treat
2006-06-04 00:13:43 +00:00
Tom Lane f2de12e50e 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.
2006-06-03 17:36:10 +00:00
Tom Lane 84e741f4f9 Fix copy-and-pasteo in Russian translation: message complaining about
HAVE_INT64_TIMESTAMP was mentioning PG_CONTROL_VERSION instead.
Victor Snezhko
2006-06-03 16:48:59 +00:00
Bruce Momjian 8a4035410f 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.
>
2006-06-03 04:00:01 +00:00
Tom Lane 12e842422f Mention pg_encoding_to_char in entry for pg_database.encoding.
Per Larry Rosenman.
2006-06-03 02:53:04 +00:00
Bruce Momjian 6ea7164feb Patch reverted, not done:
> * Allow WAL information to recover corrupted pg_controldata
2006-06-03 02:34:35 +00:00
Bruce Momjian be05b260a9 Remove pg_resetxlog -r flag, feature has problems referenced here:
http://archives.postgresql.org/pgsql-hackers/2006-05/msg00002.php
2006-06-03 02:19:24 +00:00
Teodor Sigaev a513ce2dff Fix wrong NOTICE/ERROR levels 2006-06-02 18:03:06 +00:00
Teodor Sigaev efe1d427da Distinguish between stop-word recognized in thesaurus_lexize() 2006-06-02 17:55:40 +00:00
Teodor Sigaev c7faf45160 Add more strict check of stop and non-recognized words,
allow only recognized words in thezaurus configuration file.
2006-06-02 15:35:42 +00:00
Tom Lane d77df813c9 Got tired of waiting for spoonbill's compiler to get fixed. Let's
see if using an intermediate variable avoids the gcc bug.
2006-06-01 02:39:59 +00:00
Tom Lane 87e8014d31 Respond to Jeremy Drake's original gripe that \copy needs to recognize
E'...' syntax for strings in order to track the backend.
2006-06-01 01:28:00 +00:00
Tom Lane 6178762fcf 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.
2006-06-01 00:15:36 +00:00
Tom Lane 2703007501 Fix example of how to escape data in psql backslash commands. 2006-05-31 22:34:35 +00:00
Tom Lane c6d3c1b817 Fix seriously broken patch for psql '' ... per its comment, emit() is
NOT the thing to use here.
2006-05-31 22:11:44 +00:00
Tom Lane 8f165ee13b 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.
2006-05-31 20:58:09 +00:00
Teodor Sigaev c269f0f1e2 fix comparison with SPI_processed 2006-05-31 14:53:41 +00:00
Teodor Sigaev 22505f4703 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.
2006-05-31 14:05:31 +00:00
Bruce Momjian 3b7ed9ba9c Recommend '' for literal ', rather than \', in psql documentation. 2006-05-31 11:47:20 +00:00
Bruce Momjian c3c3902611 Support '' for literal ' in psql single-quote strings, documentation update. 2006-05-31 11:35:17 +00:00
Bruce Momjian eaca1175e9 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
2006-05-31 11:02:42 +00:00
Bruce Momjian 751d985805 Update cvs command example to show diff -rBASE. 2006-05-31 10:24:29 +00:00
Michael Meskes 085e7c2fd8 Somehow a ";" got lost which changed the logic. This btw is the first fix resulting from SoC. 2006-05-31 08:12:48 +00:00
Tom Lane a0ffab351e Magic blocks don't do us any good unless we use 'em ... so install one
in every shared library.
2006-05-30 22:12:16 +00:00
Tom Lane e95703eac3 Un-DOS-ify newly added files. 2006-05-30 21:34:15 +00:00