- 14 3月, 2005 2 次提交
-
-
由 Tom Lane 提交于
a tuple are being accessed via ExecEvalVar and the attcacheoff shortcut isn't usable (due to nulls and/or varlena columns). To do this, cache Datums extracted from a tuple in the associated TupleTableSlot. Also some code cleanup in and around the TupleTable handling. Atsushi Ogawa with some kibitzing by Tom Lane.
-
由 Tom Lane 提交于
-
- 13 3月, 2005 1 次提交
-
-
由 Tom Lane 提交于
can tell whether it is being used as an aggregate or not. This allows such a function to avoid re-pallocing a pass-by-reference transition value; normally it would be unsafe for a function to scribble on an input, but in the aggregate case it's safe to reuse the old transition value. Make int8inc() do this. This gets a useful improvement in the speed of COUNT(*), at least on narrow tables (it seems to be swamped by I/O when the table rows are wide). Per a discussion in early December with Neil Conway. I also fixed int_aggregate.c to check this, thereby turning it into something approaching a supportable technique instead of being a crude hack.
-
- 11 3月, 2005 1 次提交
-
-
由 Tom Lane 提交于
Formerly, if such a clause contained no aggregate functions we mistakenly treated it as equivalent to WHERE. Per spec it must cause the query to be treated as a grouped query of a single group, the same as appearance of aggregate functions would do. Also, the HAVING filter must execute after aggregate function computation even if it itself contains no aggregate functions.
-
- 07 3月, 2005 1 次提交
-
-
由 Tom Lane 提交于
on-the-fly, and thereby avoid blowing out memory when the planner has underestimated the hash table size. Hash join will now obey the work_mem limit with some faithfulness. Per my recent proposal (hash aggregate part isn't done yet though).
-
- 11 2月, 2005 1 次提交
-
-
由 Tom Lane 提交于
that return tuples (such as EXPLAIN). Per gripe from Michael Fuhr. Side effect: fix an old bug that unintentionally disabled backward scans for all SPI-created cursors.
-
- 29 1月, 2005 1 次提交
-
-
由 Tom Lane 提交于
look at the actual aggregate transition datatypes and the actual overhead needed by nodeAgg.c, instead of using pessimistic round numbers. Per a discussion with Michael Tiemann.
-
- 28 1月, 2005 1 次提交
-
-
由 Tom Lane 提交于
functions of the aggregate, at both aggregate creation and execution times.
-
- 27 1月, 2005 1 次提交
-
-
由 Neil Conway 提交于
does not match what the query expected. From Brendan Jurd, minor editorializing by Neil Conway.
-
- 15 1月, 2005 1 次提交
-
-
由 Tom Lane 提交于
-
- 01 1月, 2005 2 次提交
-
-
由 Bruce Momjian 提交于
-
由 PostgreSQL Daemon 提交于
Tag appropriate files for rc3 Also performed an initial run through of upgrading our Copyright date to extend to 2005 ... first run here was very simple ... change everything where: grep 1996-2004 && the word 'Copyright' ... scanned through the generated list with 'less' first, and after, to make sure that I only picked up the right entries ...
-
- 12 12月, 2004 1 次提交
-
-
由 Tom Lane 提交于
of an inheritance child table is binary-compatible with the rowtype of its parent, invent an expression node type that does the conversion correctly. Fixes the new bug exhibited by Kris Shannon as well as a lot of old bugs that would only show up when using multiple inheritance or after altering the parent table.
-
- 17 11月, 2004 1 次提交
-
-
由 Tom Lane 提交于
We don't really want to start a new SPI connection, just keep using the old one; otherwise we have memory management problems as illustrated by John Kennedy's bug report of today. This requires a bit of a hack to ensure the SPI stack state is properly restored, but then again what we were doing before was a hack too, strictly speaking. Add a regression test to cover this case.
-
- 25 10月, 2004 1 次提交
-
-
由 Neil Conway 提交于
returning a NULL pointer (some callers remembered to check the return value, but some did not -- it is safer to just bail out). Also, cleanup pgstat.c to use elog(ERROR) rather than elog(LOG) followed by exit().
-
- 21 10月, 2004 1 次提交
-
-
由 Tom Lane 提交于
to make life cushy for the JDBC driver. Centralize the decision-making that affects this by inventing a get_type_func_class() function, rather than adding special cases in half a dozen places.
-
- 13 10月, 2004 2 次提交
-
-
由 Neil Conway 提交于
- remove another senseless "extern" keyword that was applied to a function definition - change a foo more function signatures from "some_type foo()" to "some_type foo(void)" - rewrite another K&R style function definition - make the type of the "action" function pointer in the KeyWord struct in src/backend/utils/adt/formatting.c more precise
-
由 Peter Eisentraut 提交于
-
- 11 10月, 2004 1 次提交
-
-
由 Neil Conway 提交于
-
- 08 10月, 2004 1 次提交
-
-
由 Tom Lane 提交于
columns. The returned tuple needs to have appropriate NULL columns inserted so that it actually matches the declared rowtype. It seemed convenient to use a JunkFilter for this, so I made some cleanups and simplifications in the JunkFilter code to allow it to support this additional functionality. (That in turn exposed a latent bug in nodeAppend.c, which is that it was returning a tuple slot whose descriptor didn't match its data.) Also, move check_sql_fn_retval out of pg_proc.c and into functions.c, where it seems to more naturally belong.
-
- 01 10月, 2004 1 次提交
-
-
由 Tom Lane 提交于
now are supposed to take some kind of lock on an index whenever you are going to access the index contents, rather than relying only on a lock on the parent table.
-
- 24 9月, 2004 1 次提交
-
-
由 Neil Conway 提交于
formerly used in execMain. Since that is no longer the case, this patch renames ExecProcAppend() to ExecAppend() for the sake of consistency.
-
- 23 9月, 2004 2 次提交
-
-
由 Tom Lane 提交于
that the inner one is completely empty. Per recent discussion. Also some cosmetic cleanups in nearby code.
-
由 Tom Lane 提交于
when a function that returns a single tuple (not a setof tuple) returns NULL. This seems to be the most consistent behavior. It would have taken a bit less code to make it return an empty table (zero rows) but ISTM a non-SETOF function ought always return exactly one row. Per bug report from Ivan-Sun1.
-
- 18 9月, 2004 1 次提交
-
-
由 Tom Lane 提交于
was large enough to be batched and the tuples fell into a batch where there were no inner tuples at all. Thanks to Xiaoyu Wang for finding a test case that exposed this long-standing bug.
-
- 17 9月, 2004 2 次提交
-
-
由 Tom Lane 提交于
subtransactions. Trivial subxacts (such as a plpgsql exception block containing no database access) now demonstrably leak zero bytes.
-
由 Tom Lane 提交于
as per recent discussions. Invent SubTransactionIds that are managed like CommandIds (ie, counter is reset at start of each top transaction), and use these instead of TransactionIds to keep track of subtransaction status in those modules that need it. This means that a subtransaction does not need an XID unless it actually inserts/modifies rows in the database. Accordingly, don't assign it an XID nor take a lock on the XID until it tries to do that. This saves a lot of overhead for subtransactions that are only used for error recovery (eg plpgsql exceptions). Also, arrange to release a subtransaction's XID lock as soon as the subtransaction exits, in both the commit and abort cases. This avoids holding many unique locks after a long series of subtransactions. The price is some additional overhead in XactLockTableWait, but that seems acceptable. Finally, restructure the state machine in xact.c to have a more orthogonal set of states for subtransactions.
-
- 14 9月, 2004 1 次提交
-
-
由 Tom Lane 提交于
mode see a fresh snapshot for each command in the function, rather than using the latest interactive command's snapshot. Also, suppress fresh snapshots as well as CommandCounterIncrement inside STABLE and IMMUTABLE functions, instead using the snapshot taken for the most closely nested regular query. (This behavior is only sane for read-only functions, so the patch also enforces that such functions contain only SELECT commands.) As per my proposal of 6-Sep-2004; I note that I floated essentially the same proposal on 19-Jun-2002, but that discussion tailed off without any action. Since 8.0 seems like the right place to be taking possibly nontrivial backwards compatibility hits, let's get it done now.
-
- 12 9月, 2004 1 次提交
-
-
由 Tom Lane 提交于
((Snapshot) NULL) can no longer be confused with a valid snapshot, as per my recent suggestion. Define a macro InvalidSnapshot for 0. Use InvalidSnapshot instead of SnapshotAny as the do-nothing special case for heap_update and heap_delete crosschecks; this seems a little cleaner even though the behavior is really the same.
-
- 11 9月, 2004 1 次提交
-
-
由 Tom Lane 提交于
rather than when returning to the idle loop. This makes no particular difference for interactively-issued queries, but it makes a big difference for queries issued within functions: trigger execution now occurs before the calling function is allowed to proceed. This responds to numerous complaints about nonintuitive behavior of foreign key checking, such as http://archives.postgresql.org/pgsql-bugs/2004-09/msg00020.php, and appears to be required by the SQL99 spec. Also take the opportunity to simplify the data structures used for the pending-trigger list, rename them for more clarity, and squeeze out a bit of space.
-
- 07 9月, 2004 1 次提交
-
-
由 Tom Lane 提交于
never worked, but it particularly doesn't work now.
-
- 29 8月, 2004 2 次提交
-
-
由 Bruce Momjian 提交于
-
由 Bruce Momjian 提交于
-
- 18 8月, 2004 1 次提交
-
-
由 Tom Lane 提交于
to the physical layout of the rowtype, ie, there are dummy arguments corresponding to any dropped columns in the rowtype. We formerly had a couple of places that did it this way and several others that did not. Fixes Gaetano Mendola's "cache lookup failed for type 0" bug of 5-Aug.
-
- 02 8月, 2004 1 次提交
-
-
由 Tom Lane 提交于
executed. Previously, the DECLARE would succeed but subsequent FETCHes would fail since the parameter values supplied to DECLARE were not propagated to the portal created for the cursor. In support of this, add type Oids to ParamListInfo entries, which seems like a good idea anyway since code that extracts a value can double-check that it got the type of value it was expecting. Oliver Jowett, with minor editorialization by Tom Lane.
-
- 01 8月, 2004 1 次提交
-
-
由 Tom Lane 提交于
Create a shared function to convert a SPI error code into a string (replacing near-duplicate code in several PLs), and use it anywhere that a SPI function call error is reported.
-
- 27 7月, 2004 1 次提交
-
-
由 Tom Lane 提交于
SAVEPOINT/RELEASE/ROLLBACK-TO syntax. (Alvaro) Cause COMMIT of a failed transaction to report ROLLBACK instead of COMMIT in its command tag. (Tom) Fix a few loose ends in the nested-transactions stuff.
-
- 15 7月, 2004 1 次提交
-
-
由 Tom Lane 提交于
sure the tuple datums it returns actually show that type and not RECORD.
-
- 11 7月, 2004 1 次提交
-
-
由 Tom Lane 提交于
This is required by SQL spec to avoid failures in cases like SELECT sum(win)/sum(lose) FROM ... GROUP BY ... HAVING sum(lose) > 0; AFAICT we have gotten this wrong since day one. Kudos to Holger Jakobs for being the first to notice.
-
- 02 7月, 2004 1 次提交
-
-
由 Tom Lane 提交于
for cleaning up. It seems possible that the memory contexts SPI_finish would try to touch are already gone; and there's no need for SPI itself to delete them, since the containing contexts will surely be going away anyway at transaction end.
-