aboutsummaryrefslogtreecommitdiff
path: root/src/backend
Commit message (Collapse)AuthorAge
* Fix ALTER TABLE OWNER to adjust the ownership of dependent sequences,Tom Lane2004-09-23
| | | | not only indexes. Alvaro Herrera, with some kibitzing by Tom Lane.
* If we're going to print unrecognized result codes from SSL_get_errorTom Lane2004-09-23
| | | | | in open_client_SSL, surely we should do it everywhere. Also make message formatting conform to style guide.
* Arrange for hash join to skip scanning the outer relation if it detectsTom Lane2004-09-22
| | | | | that the inner one is completely empty. Per recent discussion. Also some cosmetic cleanups in nearby code.
* Adjust ExecMakeTableFunctionResult to produce a single all-nulls rowTom Lane2004-09-22
| | | | | | | | 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.
* This patch from Alvaro Herrera adds transaction ID to the list ofNeil Conway2004-09-22
| | | | | | log_line_prefix escapes. The escape sequence used for this is %x. %x previously meant "postmaster et al. stop here" -- this has been renamed to %q.
* Rotate on time boundaries that are sensible per local time rather than GMT.Tom Lane2004-09-21
| | | | | Also, avoid truncating the file we just wrote into, which might otherwise easily happen at DST boundaries. Ed L. and Tom Lane.
* Documentation improvements, per Josh Berkus.Tom Lane2004-09-20
|
* Translation updatePeter Eisentraut2004-09-20
|
* Translation updatesPeter Eisentraut2004-09-20
|
* Translation updatesPeter Eisentraut2004-09-20
|
* Fix estimate_num_groups to be able to use expression-index statisticsTom Lane2004-09-18
| | | | when there is an expressional index matching a GROUP BY item.
* Fix memory leak in tokenize_file, per report from Vadim Passynkov.Tom Lane2004-09-18
|
* Allow WIN1250 as server encoding.Peter Eisentraut2004-09-17
|
* Hashed LEFT JOIN would miss outer tuples with no inner match if the joinTom Lane2004-09-17
| | | | | | 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.
* Now that xmax and cmin are distinct fields again, we should zero xmax whenTom Lane2004-09-17
| | | | | | creating a new tuple. This is just for debugging sanity, though, since nothing should be paying any attention to xmax when the HEAP_XMAX_INVALID bit is set.
* Remove erroneous Assert, per example from Kris Jurka.Tom Lane2004-09-16
|
* Add some marginal tweaks to eliminate memory leakages associated withTom Lane2004-09-16
| | | | | subtransactions. Trivial subxacts (such as a plpgsql exception block containing no database access) now demonstrably leak zero bytes.
* RecentXmin is too recent to use as the cutoff point for accessingTom Lane2004-09-16
| | | | | | | pg_subtrans --- what we need is the oldest xmin of any snapshot in use in the current top transaction. Introduce a new variable TransactionXmin to play this role. Fixes intermittent regression failure reported by Neil Conway.
* Restructure subtransaction handling to reduce resource consumption,Tom Lane2004-09-16
| | | | | | | | | | | | | | | | | 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.
* Fix a read of uninitialized memory in array_out(). Perform some minorNeil Conway2004-09-16
| | | | cosmetic code cleanup at the same time.
* Translation updatePeter Eisentraut2004-09-14
|
* Translation updatePeter Eisentraut2004-09-13
|
* Redesign query-snapshot timing so that volatile functions in READ COMMITTEDTom Lane2004-09-13
| | | | | | | | | | | | | 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.
* Translation updatesPeter Eisentraut2004-09-13
|
* Fix two typos in comments.Neil Conway2004-09-13
|
* When LockAcquire fails at the stage of creating a proclock object, beTom Lane2004-09-12
| | | | | sure to clean up the already-created lock object, if it has no other references. Avoids possibly-permanent leak of shared memory.
* Renumber SnapshotNow and the other special snapshot codes so thatTom Lane2004-09-11
| | | | | | | | ((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.
* Ensure that pg_largeobject references opened by lo_import() or lo_export()Tom Lane2004-09-11
| | | | | will be cleaned up at end of transaction, even when there is no other LO operation in the transaction. Per bug report from Daniel Schuchardt.
* Fire non-deferred AFTER triggers immediately upon query completion,Tom Lane2004-09-10
| | | | | | | | | | | | | 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.
* More cleanup.Bruce Momjian2004-09-10
|
* Added a call to gettext() to fix broken translated error messages.Dennis Bjorklund2004-09-09
|
* Translation updatesDennis Bjorklund2004-09-09
|
* Translation updatesDennis Bjorklund2004-09-09
|
* Fix Cygwin defines to be consistent.Bruce Momjian2004-09-09
|
* Minor efficiency improvements in keeping track of trigger deferredTom Lane2004-09-08
| | | | | | | | status. In particular, I see no reason for deferredTriggerCheckState to make an explicit entry to note that a particular trigger has its default state --- that just clutters a list that should normally be empty or very short. I have plans to revise this module much more heavily, but this is a simple separable improvement.
* Fix a couple of small errors in trigger-list management, as per recentTom Lane2004-09-07
| | | | discussion.
* Fix places where WaitForxxx can block, to eliminate failure to detectTom Lane2004-09-07
| | | | deadlock on Win32. Magnus Hagander
* Fix a number of places where brittle data structures or overly strongTom Lane2004-09-06
| | | | | | | | | Asserts would lead to a server core dump if an error occurred while trying to abort a failed subtransaction (thereby leading to re-execution of whatever parts of AbortSubTransaction had already run). This of course does not prevent such an error from creating an infinite loop, but at least we don't make the situation worse. Responds to an open item on the subtransactions to-do list.
* Guard against transaction control statements in SQL functions. ThisTom Lane2004-09-06
| | | | never worked, but it particularly doesn't work now.
* Fix incorrect ordering of smgr cleanup relative to buffer pin cleanupTom Lane2004-09-06
| | | | | during transaction abort. Add a regression test case to catch related mistakes in future. Alvaro Herrera and Tom Lane.
* I can't see any good reason for DropRelFileNodeBuffers to be issuingTom Lane2004-09-06
| | | | FATAL when it detects a nonzero reference count. Reduce to ERROR.
* Downgrade LOG messages to DEBUG1 for normal recycling of xlog, clog,Tom Lane2004-09-06
| | | | subtrans segments. Per Greg Mullane and Chris K-L.
* On further consideration, there's another problem here: the existingTom Lane2004-09-05
| | | | | | | elog() emulation code always calls errstart with ERROR error level. This means that a recursive error call triggered by elog would do MemoryContextReset(ErrorContext), whether or not this was actually appropriate. I'm surprised we haven't seen this in the field...
* Tweak elog.c's logic for promoting errors into more severe errors.Tom Lane2004-09-05
| | | | | | | | | Messages of less than ERROR severity should never be promoted (this fixes Gaetano Mendola's problem with a COMMERROR becoming a PANIC, and is obvious in hindsight anyway). Do all promotion in errstart not errfinish, to ensure that output decisions are made correctly; the former coding could suppress logging of promoted errors, which doesn't seem like a good idea. Eliminate some redundant code too.
* Yet another place where someone was being careless about the argumentsTom Lane2004-09-02
| | | | of <ctype.h> macros.
* Cope with recent HPUX versions providing isfinite() instead of finite().Tom Lane2004-09-02
|
* Remove obsolete comment.Tom Lane2004-09-02
|
* Tweak prettyprinting rules for saner indenting of UNION, INTERSECT,Tom Lane2004-09-01
| | | | EXCEPT constructs.
* Fix mistaken comment.Tom Lane2004-09-01
|
* needs_toast_table() should ignore dropped columns.Tom Lane2004-08-31
|