Commit Graph

14573 Commits

Author SHA1 Message Date
Tom Lane 887edf4ff7 Update release history for 7.2.4. 2003-01-29 22:14:08 +00:00
Tom Lane 26f56131ae SPI_exec shouldn't return SPI_OK_SELECT if it hasn't actually returned
a tuple table.  Fixes core dump in pltcl (and probably other PLs) when
executing a query rewritten by a rule.  Per bug report from Wolfgang Walter.
2003-01-29 15:24:46 +00:00
Bruce Momjian 6976205b4b Update release steps. 2003-01-29 03:41:54 +00:00
Tom Lane 5fdb142f16 Tweak ArrayCount() to forestall possible access to temp[-1]. Problem
cannot actually happen at present because ArrayCount() is only called
on strings beginning with '{', but seems best to prevent it going forward.
Per report from Yichen Xie.
2003-01-29 01:28:33 +00:00
Tom Lane 3cb282f3e6 Guard against array overrun, per report from Yichen Xie. This case
can only occur if the constant DEFAULT_CLIENT_AUTHSVC is given a bogus
value, so it doesn't seem worth back-patching, but I'll fix it in HEAD.
2003-01-29 01:18:21 +00:00
Tom Lane 23b8a0ce61 Repair array subscript overrun identified by Yichen Xie. Reduce the
value of MAX_TIME_PRECISION in floating-point-timestamp-storage case
from 13 to 10, which is as much as time_out is actually willing to print.
(The alternative of increasing the number of digits we are willing to
print looks risky; we might find ourselves printing roundoff garbage.)
2003-01-29 01:08:42 +00:00
Tom Lane b8add56ed0 Fix array subscript overruns identified by Yichen Xie. 2003-01-29 01:01:05 +00:00
Tom Lane 2e46b762eb Extend join-selectivity API (oprjoin interface) so that join type is
passed to join selectivity estimators.  Make use of this in eqjoinsel
to derive non-bogus selectivity for IN clauses.  Further tweaking of
cost estimation for IN.
initdb forced because of pg_proc.h changes.
2003-01-28 22:13:41 +00:00
Peter Eisentraut 955a1f81a7 Factor out the code that detects the long long int snprintf format into a
separate macro.  Also add support for %I64d which is the way on Windows.

The code that checks for the 64-bit int type now gives more reasonable
results when cross-compiling: In that case we just take the compiler's
information and trust that the arithmetic works.  Disabling int64 is too
pessimistic.
2003-01-28 21:57:12 +00:00
Tom Lane c0276244b1 Convert variable name to canonical spelling before checking for matches
in GUCArrayAdd/GUCArrayDelete.  This prevents the multiple-entry bug
exhibited by Frank Lupo 28-Jan-2003.
2003-01-28 18:04:02 +00:00
Bruce Momjian 7af352d091 Revert off setting mention for client_min_messages.
Set log_min_error_messages to the proper and agreed-upon default, PANIC
(off).  (BACKPATCH)
2003-01-28 03:43:47 +00:00
Bruce Momjian f21fb30dfc Revert optimizer page count change. 2003-01-28 03:34:29 +00:00
Bruce Momjian bd175cc9fb Set log_min_error_messages to the proper and agreed-upon default, PANIC (off).
Backpatch to 7.3.X.
2003-01-27 23:55:38 +00:00
Bruce Momjian d42a476621 Add blank line. 2003-01-27 23:19:18 +00:00
Bruce Momjian c177ba99bd Move:
> * Add the concept of dataspaces/tablespaces [tablespaces]
307d307
< * Add the concept of dataspaces/tablespaces [tablespaces]
2003-01-27 23:16:52 +00:00
Bruce Momjian 9b9b14915b Fix typo 233 pages -> 333 pages. 2003-01-27 22:40:56 +00:00
Tom Lane 70fba70430 Upgrade cost estimation for joins, per discussion with Bradley Baetz.
Try to model the effect of rescanning input tuples in mergejoins;
account for JOIN_IN short-circuiting where appropriate.  Also, recognize
that mergejoin and hashjoin clauses may now be more than single operator
calls, so we have to charge appropriate execution costs.
2003-01-27 20:51:54 +00:00
Bruce Momjian b2773d4099 Remove mention of 6.5 max backends. 2003-01-27 06:25:03 +00:00
Tom Lane 33875872fd Get rid of last few unadorned 'permission denied' messages. 2003-01-27 00:51:06 +00:00
Tom Lane 4b833d080b Prevent core dump when die_horribly() is called with null AH pointer.
Problem reported and fixed by Oliver Elphick.
2003-01-27 00:23:38 +00:00
Bruce Momjian 4dc2bceef4 Mark IN performance problem as fixed in 7.4 2003-01-26 02:43:55 +00:00
Bruce Momjian dc87ea755c Include IPv6 addresses in pg_hba.conf even if IPv6 is not supported; at
suggestion of Peter.
2003-01-26 01:19:22 +00:00
Bruce Momjian 677d77817d Add:
> * Add group object ownership, so groups can rename/drop/grant on objects,
>   so we can implement roles
2003-01-26 01:13:34 +00:00
Tom Lane 9f5f212475 Allow the planner to collapse explicit inner JOINs together, rather than
necessarily following the JOIN syntax to develop the query plan.  The old
behavior is still available by setting GUC variable JOIN_COLLAPSE_LIMIT
to 1.  Also create a GUC variable FROM_COLLAPSE_LIMIT to control the
similar decision about when to collapse sub-SELECT lists into their parent
lists.  (This behavior existed already, but the limit was always
GEQO_THRESHOLD/2; now it's separately adjustable.)
2003-01-25 23:10:30 +00:00
Tom Lane 15ab7a8720 Where available, use utime() or utimes() to update the file mod time
of the socket file and socket lock file; this should prevent both of them
from being removed by even the stupidest varieties of /tmp-cleaning
script.  Per suggestion from Giles Lean.
2003-01-25 05:19:47 +00:00
Tom Lane 80727ce14f Use stat(2) to probe for existing xlog segments in InstallXLogFileSegment,
rather than actually opening the files.  This eliminates some corner cases
where the file indeed exists but open() fails for another reason, such
as being out of file descriptors.  The net reliability gain is probably
tiny, since xlog.c is full of other file open calls that will elog(PANIC)
if they fail for any reason; but this specific failure mode has been
observed in the field, so we may as well fix it.
2003-01-25 03:06:04 +00:00
Tom Lane 7a196bab23 Suppress gcc warnings. 2003-01-24 21:53:29 +00:00
Tom Lane f5e83662d0 Modify planner's implied-equality-deduction code so that when a set
of known-equal expressions includes any constant expressions (including
Params from outer queries), we actively suppress any 'var = var'
clauses that are or could be deduced from the set, generating only the
deducible 'var = const' clauses instead.  The idea here is to push down
the restrictions implied by the equality set to base relations whenever
possible.  Once we have applied the 'var = const' clauses, the 'var = var'
clauses are redundant, and should be suppressed both to save work at
execution and to avoid double-counting restrictivity.
2003-01-24 03:58:44 +00:00
Peter Eisentraut ef7422510e Grant options, and cascading revoke. Grant options are allowed only for
users right now, not groups.  Extension of has_foo_privileges functions to
query the grant options.  Extension of aclitem type to store grantor.
2003-01-23 23:39:07 +00:00
Dave Cramer aa78ca3a95 added fix from Joel Hock to get the inserted row into the current buffer 2003-01-23 18:49:22 +00:00
Tom Lane 36777c1e35 Fix obsolete error message (isImmutable doesn't exist). 2003-01-23 15:18:40 +00:00
Tom Lane 790d5bc992 Change CREATE TABLE AS / SELECT INTO to create the new table with OIDs,
for backwards compatibility with pre-7.3 behavior.  Per discussion on
pgsql-general and pgsql-hackers.
2003-01-23 05:10:41 +00:00
Tom Lane 742403bdad Update 'Mathematical Functions' table to reflect 7.3 addition of float8
forms of ceil(), floor(), sign().  Back-patch this and other recent
doc fixes in this file to the 7.3 branch.
2003-01-23 01:22:59 +00:00
Tom Lane b3d7af46a9 Fix sloppy comment. 2003-01-22 20:44:20 +00:00
Tom Lane c4d0ff32e9 Make estimation of mergejoin scan selectivities more robust, per recent
example from RaÇl GutiÅrrez.
2003-01-22 20:16:42 +00:00
Tom Lane c7b4047234 Improve print_expr() a little. It's still not very bright though. 2003-01-22 19:26:35 +00:00
Tom Lane e2114817c7 Implement choice between hash-based and sort-based grouping for doing
DISTINCT processing on the output of an IN sub-select.
2003-01-22 00:07:00 +00:00
Tom Lane a4482f4c4c Fix coredump problem in plpgsql's RETURN NEXT. When a SELECT INTO
that's selecting into a RECORD variable returns zero rows, make it
assign an all-nulls row to the RECORD; this is consistent with what
happens when the SELECT INTO target is not a RECORD.  In support of
this, tweak the SPI code so that a valid tuple descriptor is returned
even when a SPI select returns no rows.
2003-01-21 22:06:12 +00:00
Michael Meskes f8d8266ac5 Synced parser. 2003-01-21 20:01:12 +00:00
Tom Lane 1a7c6ee8c6 Avoid gratuitous variation in spelling of same error message. 2003-01-21 19:44:26 +00:00
Peter Eisentraut 980acc8329 Fix sed expression for BSD sed. 2003-01-21 10:11:52 +00:00
Tom Lane bdfbfde1b1 IN clauses appearing at top level of WHERE can now be handled as joins.
There are two implementation techniques: the executor understands a new
JOIN_IN jointype, which emits at most one matching row per left-hand row,
or the result of the IN's sub-select can be fed through a DISTINCT filter
and then joined as an ordinary relation.
Along the way, some minor code cleanup in the optimizer; notably, break
out most of the jointree-rearrangement preprocessing in planner.c and
put it in a new file prep/prepjointree.c.
2003-01-20 18:55:07 +00:00
Bruce Momjian be2b660ecd This patch includes a lot of minor cleanups to the SGML documentation,
including:

- replacing all the appropriate usages of <citetitle>PostgreSQL
...</citetitle> with &cite-user;, &cite-admin;, and so on

- fix an omission in the EXECUTE documentation

- add some more text to the EXPLAIN documentation

- improve the PL/PgSQL RETURN NEXT documentation (more work to do here)

- minor markup fixes


Neil Conway
2003-01-19 00:13:31 +00:00
Bruce Momjian 2042daf5c3 Improve symlink handling for C tags file. 2003-01-18 06:06:51 +00:00
Bruce Momjian d12be5c37b Add section on testing index scan. 2003-01-17 17:15:14 +00:00
Bruce Momjian 3c731e0ed7 Add dash to:
set-returning functions or SRF's.

for clarity.
2003-01-17 03:28:18 +00:00
Tom Lane b19adc1aae Fix parse_agg.c to detect ungrouped Vars in sub-SELECTs; remove code
that used to do it in planner.  That was an ancient kluge that was
never satisfactory; errors should be detected at parse time when possible.
But at the time we didn't have the support mechanism (expression_tree_walker
et al) to make it convenient to do in the parser.
2003-01-17 03:25:04 +00:00
Tom Lane a4d82dd4b4 Adjust API of expression_tree_mutator and query_tree_mutator to
simplify callers.  It turns out the common case is that the caller
does want to recurse into sub-queries, so push support for that into
these subroutines.
2003-01-17 02:01:21 +00:00
Tom Lane 227a404cf4 Add code to print information about a detected deadlock cycle. The
printed data is comparable to what you could read in the pg_locks view,
were you fortunate enough to have been looking at it at the right time.
2003-01-16 21:01:45 +00:00
Tom Lane 136828c699 Ooops, didn't cut-and-paste quite enough code from ResolveNew;
with result that flatten_join_alias_vars failed to descend into subselects.
2003-01-16 18:26:02 +00:00