aboutsummaryrefslogtreecommitdiff
path: root/src/backend
Commit message (Collapse)AuthorAge
* Remove unnecessary inclusion, per Andreas.Tom Lane2002-11-04
|
* Remove no-longer-needed inclusion of bootstrap_tokens.h, per patchTom Lane2002-11-04
| | | | from Andreas.
* Code review for recent patch to allow ALTER TABLE ADD COLUMN whenTom Lane2002-11-02
| | | | | | a child table already has a matching column. Acquire appropriate lock on child table; do the right thing with any CHECK constraints attached to the new parent column.
* During swap_relfilenodes, swap relation size statistic fields along withTom Lane2002-11-02
| | | | | the relfilenode and toast fields. This ensures that the newly-computed statistics will be available on completion of CLUSTER.
* Remove encoding lookups from grammar stage, push them back to placesTom Lane2002-11-02
| | | | | | where it's safe to do database access. Along the way, fix core dump for 'DEFAULT' parameters to CREATE DATABASE. initdb forced due to change in pg_proc entry.
* Clean up a few fprintf(stderr)'s that should be elog's.Tom Lane2002-11-02
|
* Fix permissions-checking bugs and namespace-search-path bugs inTom Lane2002-11-02
| | | | | CONVERSION code. Still need to figure out what to do about inappropriate coding in parsing.
* Arrange to compile flex output files as inclusions into other filesTom Lane2002-11-01
| | | | | | | | (usually bison output files), not as standalone files. This hack works around flex's insistence on including <stdio.h> before we are able to include postgres.h; postgres.h will already be read before the compiler starts to read the flex output file. Needed for largefile support on some platforms.
* Reduce a couple of debugging messages from LOG to DEBUG1 category.Tom Lane2002-11-01
|
* Reduce messages associated with shell-type function arguments/resultsTom Lane2002-11-01
| | | | from WARNING to NOTICE, since they are expected messages in common cases.
* After elog(PANIC), exit with abort() not proc_exit(). This allows aTom Lane2002-11-01
| | | | | | core file to be produced for debugging, and avoids trying to run the normal proc-exit cleanup hooks, which are likely to cause additional problems if the system is hosed.
* Fix some bogus comments.Tom Lane2002-11-01
|
* Add missing #include <errno.h>, per gripe from Alessio Bragadini.Tom Lane2002-10-31
|
* Got tired of explaining why this Assert is not wrong.Tom Lane2002-10-31
|
* Code review for statement_timeout patch. Fix some race conditionsTom Lane2002-10-31
| | | | | | between signal handler and enable/disable code, avoid accumulation of timing error due to trying to maintain remaining-time instead of absolute-end-time, disable timeout before commit not after.
* Fix miscalculation of remaining free space during tuple chain moving.Tom Lane2002-10-31
| | | | | | | Only affects machines where MAXALIGN > 4, and is a boundary-condition case even there, but still surprising that it's not been identified before. Also reduce tuple chain move give-up messages from WARNING to DEBUG1, since they are not unexpected conditions.
* Avoid use of inline functions that are not declared static. Needed toTom Lane2002-10-31
| | | | conform to C99's brain-dead notion of how inline functions should work.
* Clean up gram.y trailing spaces.Bruce Momjian2002-10-31
|
* Add missing semicolons to a few PG_FUNCTION_INFO_V1 calls.Tom Lane2002-10-26
|
* Fix some places that were unportably assuming struct timeval's tv_secTom Lane2002-10-24
| | | | field is signed. Clean up casting.
* Function-call-style type coercions should be treated as explicitTom Lane2002-10-24
| | | | | | coercions, not implicit ones. For example, 'select abstime(1035497293)' should succeed because there is an explicit binary coercion from int4 to abstime.
* Perform transaction cleanup operations in a less ad-hoc, moreTom Lane2002-10-22
| | | | | | | | | | | principled order; in particular ensure that all shared resources are released before we release transaction locks. The code used to release locks before buffer pins, which might explain an ancient note I have about a bufmgr assertion failure I'd seen once several years ago, and been unable to reproduce since. (Theory: someone trying to drop a relation might be able to reach FlushRelationBuffers before the last user of the relation had gotten around to dropping his buffer pins.)
* Fix places that were using IsTransactionBlock() as an (inadequate) checkTom Lane2002-10-21
| | | | | | that they'd get to commit immediately on finishing. There's now a centralized routine PreventTransactionChain() that implements the necessary tests.
* Fix ALTER TABLE ... ADD COLUMN for inheritance cases.Bruce Momjian2002-10-21
| | | | Alvaro Herrera
* Remove unnecessary (and inadequate) check of IsTransactionBlock() inTom Lane2002-10-21
| | | | | pgstat_vacuum_tabstat(). Assume that caller (namely, VACUUM) has done the appropriate state checking beforehand.
* Avoid using IsTransactionBlock() in DeferredTriggerSetState(); no realTom Lane2002-10-21
| | | | need for this optimization, and it's too easily fooled anyway.
* Make CREATE/ALTER/DROP USER/GROUP transaction-safe, or at least prettyTom Lane2002-10-21
| | | | | nearly so, by postponing write of flat password file until transaction commit.
* Fix potential problem with btbulkdelete deleting an indexscan's currentTom Lane2002-10-20
| | | | | | | | | | | | item, if the page containing the current item is split while the indexscan is stopped and holds no read-lock on the page. The current item might move right onto a page that the indexscan holds no pin on. In the prior code this would allow btbulkdelete to reach and possibly delete the item, causing 'my bits moved right off the end of the world!' when the indexscan finally resumes. Fix by chaining read-locks to the right during _bt_restscan and requiring btbulkdelete to LockBufferForCleanup on every page it scans, not only those with deletable items. Per my pghackers message of 25-May-02. (Too bad no one could think of a better way.)
* Rule rewriter was doing the wrong thing with conditional INSTEAD rulesTom Lane2002-10-20
| | | | | | | | | whose conditions might yield NULL. The negated qual to attach to the original query is properly 'x IS NOT TRUE', not 'NOT x'. This fix produces correct behavior, but we may be taking a performance hit because the planner is much stupider about IS NOT TRUE than it is about NOT clauses. Future TODO: teach prepqual, other parts of planner how to cope with BooleanTest clauses more effectively.
* Disallow aggregate functions in rule WHERE clauses. Per gripe fromTom Lane2002-10-20
| | | | Fritz Lehmann-Grube back in January.
* Fix case where a function in FROM returns a scalar type, but isTom Lane2002-10-19
| | | | referred to with whole-tuple syntax.
* Invert logic in pg_exec_query_string() so that we set a snapshot forTom Lane2002-10-19
| | | | | | | all utility statement types *except* a short list, per discussion a few days ago. Add missing SetQuerySnapshot calls in VACUUM and REINDEX, and guard against calling REINDEX DATABASE from a function (has same problem as VACUUM).
* Fix rewrite code so that rules are in fact executed in order by name,Tom Lane2002-10-19
| | | | | | | | | | rather than being reordered according to INSTEAD attribute for implementation convenience. Also, increase compiled-in recursion depth limit from 10 to 100 rewrite cycles. 10 seems pretty marginal for situations where multiple rules exist for the same query. There was a complaint about this recently, so I'm going to bump it up. (Perhaps we should make the limit a GUC parameter, but that's too close to being a new feature to do in beta.)
* Back out Alvaro's patch until regression tests pass.Bruce Momjian2002-10-19
|
* Fix range-query estimation to not double-exclude NULLs, per gripe fromTom Lane2002-10-19
| | | | | | | | Ray Ontko 28-June-02. Also, fix prefix_selectivity for NAME lefthand variables (it was bogusly assuming binary compatibility), and adjust make_greater_string() to not call pg_mbcliplen() with invalid multibyte data (this last per bug report that I can't find at the moment, but it was in July '02).
* Fix compile failure caused by new patch.Bruce Momjian2002-10-19
|
* > Huh, I don't know where I got the idea you were (or someone else was?)Bruce Momjian2002-10-19
| | | | | | | | | | | | | | > in the position that attislocal should be reset. I'll clean everything > up and submit the patch I had originally made. All right, this is it. This patch merely checks if child tables have the column. If atttypid and atttypmod are the same, the attributes' attinhcount is incremented; else the operation is aborted. If child tables don't have the column, recursively add it. attislocal is not touched in any case. Alvaro Herrera
* This patch adds some missing functions for float8 math operations,Bruce Momjian2002-10-19
| | | | | | | | specifically ceil(), floor(), and sign(). There may be other functions that need to be added, but this is a start. I've included some simple regression tests. Neil Conway
* Add missing #include <errno.h>.Tom Lane2002-10-19
|
* Improve formatting of --help output.Peter Eisentraut2002-10-18
|
* Fix breakage that had crept into setlocale() usage: once again we'veTom Lane2002-10-18
| | | | | | been bit by the fact that the locale functions return pointers to modifiable variables. I added some comments that might help us avoid the mistake in future.
* Fix Linux dynloader code for pre-HAVE_DLOPEN systems, which evidentlyTom Lane2002-10-15
| | | | are still in use out there. Per report from Brendan LeFebvre.
* Make SPI's execution of querystrings follow the rules agreed to forTom Lane2002-10-14
| | | | | | | command status at the interactive level. SPI_processed, etc are set in the same way as the returned command status would have been set if the same querystring were issued interactively. Per gripe from Michael Paesold 25-Sep-02.
* Adjust handling of command status strings in the presence of rules,Tom Lane2002-10-14
| | | | | as per recent pghackers discussions. initdb forced due to change in fields of stored Query nodes.
* Translation updatesPeter Eisentraut2002-10-14
|
* Arrange to copy relcache's trigdesc structure at the start of anyTom Lane2002-10-14
| | | | | | | | | | | | query that uses it. This ensures that triggers will be applied consistently throughout a query even if someone commits changes to the relation's pg_class.reltriggers field meanwhile. Per crash report from Laurette Cisneros. While at it, simplify memory management in relcache.c, which no longer needs the old hack to try to keep trigger info in the same place over a relcache entry rebuild. (Should try to fix rd_att and rewrite-rule access similarly, someday.) And make RelationBuildTriggers simpler and more robust by making it build the trigdesc in working memory and then CopyTriggerDesc() into cache memory.
* As Niel so nicely pointed out this morning, the output of EXPLAINBruce Momjian2002-10-14
| | | | | | | | | | ANALYZE is not quite clear when branches of the query are never executed. So this tiny patch fixes that. The patch is attached and can also be found at: http://svana.org/kleptog/pgsql/pgsql-explain.patch Martijn van Oosterhout
* Make SET really not start a transaction.Tom Lane2002-10-13
|
* Make macaddr_in reject trailing garbage (except whitespace).Tom Lane2002-10-13
| | | | Per gripe from Patrick Welche, 13-Oct-2002.
* Fix for bug #795: two clauses that seem redundant are not really, ifTom Lane2002-10-12
| | | | one is pushed down into an outer join and the other is not.