summaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Collapse)Author
2005-12-18Add new psql command \password for changing role password with client-sidePeter Eisentraut
password encryption. Also alter createuser command to the same effect.
2005-12-17Fix typo.Bruce Momjian
2005-12-17Update s_lock.c comments.Bruce Momjian
2005-12-17Update ASM comments.Bruce Momjian
2005-12-16Add a note to Win32 gettimeofday() emulation, per Qingqing Zhou.Alvaro Herrera
2005-12-16Rethink prior patch to filter out dead backend entries from the pgstatsTom Lane
file. The original code probed the PGPROC array separately for each PID, which was not good for large numbers of backends: not only is the runtime O(N^2) but most of it is spent holding ProcArrayLock. Instead, take the lock just once and copy the active PIDs into an array, then use qsort and bsearch so that the lookup time is more like O(N log N).
2005-12-14Defend against crash while processing Describe Statement or Describe PortalTom Lane
messages, when client attempts to execute these outside a transaction (start one) or in a failed transaction (reject message, except for COMMIT/ROLLBACK statements which we can handle). Per report from Francisco Figueiredo Jr.
2005-12-14Fix problem with whole-row Vars referencing sub-select outputs, perTom Lane
example from Jim Dew. Add some simple regression tests, since this is an area we seem to break regularly :-(
2005-12-12Use a proper enum for tri-valued variables.Bruce Momjian
2005-12-12Document tri-valued variables in createdb, +1, -1, 0.Bruce Momjian
2005-12-11Divide the lock manager's shared state into 'partitions', so as toTom Lane
reduce contention for the former single LockMgrLock. Per my recent proposal. I set it up for 16 partitions, but on a pgbench test this gives only a marginal further improvement over 4 partitions --- we need to test more scenarios to choose the number of partitions.
2005-12-11Implement IS NOT DISTINCT FROM, update the regression tests and docs.Neil Conway
Patch from Pavel Stehule, minor fixups by myself.
2005-12-10Teach deparsing of CASE expressions to cope with the simplified formsTom Lane
that simplify_boolean_equality() may leave behind. This is only relevant if the user writes something a bit silly, like CASE x=y WHEN TRUE THEN. Per example from Michael Fuhr; may or may not explain bug #2106.
2005-12-09Allow installation into directories containing spaces in the name.Peter Eisentraut
2005-12-09Fix core dump in error path of plpgsql_parse_tripwordtype. SomebodyTom Lane
introduced a copy-and-pasteo while trying to simplify the code.
2005-12-09Let initdb detect the date order of the lc_time locale and initialize thePeter Eisentraut
datestyle parameter of the new cluster accordingly.
2005-12-09I reconfirmed MS-VC6. Thank you for wonderful correspondence.Bruce Momjian
However, Another problem newly occurred. This solves the problem of snprintf and vsnprintf. Patch to HEAD and 8.1.X. Hiroshi Saito
2005-12-09Stamp libraries for 8.2 by updating minor library version numbers andBruce Momjian
Win32 library files.
2005-12-09Simplify lock manager data structures by making a clear separation betweenTom Lane
the data defining the semantics of a lock method (ie, conflict resolution table and ancillary data, which is all constant) and the hash tables storing the current state. The only thing we give up by this is the ability to use separate hashtables for different lock methods, but there is no need for that anyway. Put some extra fields into the LockMethod definition structs to clean up some other uglinesses, like hard-wired tests for DEFAULT_LOCKMETHOD and USER_LOCKMETHOD. This commit doesn't do anything about the performance issues we were discussing, but it clears away some of the underbrush that's in the way of fixing that.
2005-12-08> 1) I'm proposing a patch to do the DROP FUNCTION argument tab completion.Bruce Momjian
> Now, the arguments of the drop function can be tab completed. for example > > drop function strpos ( > <press tab> > drop FUNCTION strpos (text, text) > > or: > > wsdb=# drop FUNCTION length ( > bit) bytea) character) lseg) path) text) > <press c> > wsdb# DROP FUNCTION length ( character) > > I think that this patch should be rather useful. At it least I hate > always to type all the arguments of the dropped functions. > > 2) Also some fixes applied for the > CREATE INDEX syntax > > now the parenthesises are inserted by tab pressing. > suppose I have the table q3c: Sergey E. Koposov
2005-12-08Add missing translation markerPeter Eisentraut
2005-12-08Fix bgwriter's failure to release buffer pins and open files after anTom Lane
error. This probably explains bug #2099 and could also account for mysterious VACUUM hangups.
2005-12-08Disble some Win32-specific code in win32-client-only builds:Bruce Momjian
I have the problem, when building by MS-VC6. An error occurs in the 8.1.0 present source codes. nmake -f win32.mak ..\..\port\getaddrinfo.c(244) : error C2065: 'WSA_NOT_ENOUGH_MEMORY' ..\..\port\getaddrinfo.c(342) : error C2065: 'WSATYPE_NOT_FOUND' This is used by winsock2.h. However, Construction of a windows base is winsock.h. Then, Since MinGW has special environment, this is right. but, it is not found in VC6. Furthermore, in getaddrinfo.c, IPV6-API is used by LoadLibraryA("ws2_32"); Referring to of dll the external memory generates this violation by VC6 specification. I considered whether the whole should have been converted into winsock2. However, Now, DLL of MinGW creation operates wonderfully as it is. That's right, it has pliability by replacement of simple DLL. Then, I propose the system using winsock(non IPV6) in construction of VC6. Hiroshi Saito
2005-12-08Fix thinko in comment.Tom Lane
2005-12-07Push the responsibility for handling ignore_killed_tuples down intoTom Lane
_bt_checkkeys(), instead of checking it in the top-level nbtree.c routines as formerly. This saves a little bit of loop overhead, but more importantly it lets us skip performing the index key comparisons for dead tuples.
2005-12-07A couple of tiny performance hacks in _bt_step(). Remove PageIsEmptyTom Lane
checks, which were once needed because PageGetMaxOffsetNumber would fail on empty pages, but are now just redundant. Also, don't set up local variables that aren't needed in the fast path --- most of the time, we only need to advance offnum and not step across a page boundary. Motivated by noticing _bt_step at the top of OProfile profile for a pgbench run.
2005-12-07Fix a couple of lingering references to POSTQUEL query syntax, per Simon.Tom Lane
2005-12-07Spell "explicitly" correctly, per Simon.Tom Lane
2005-12-06Get rid of slru.c's hardwired insistence on a fixed number of slots perTom Lane
SLRU area. The number of slots is still a compile-time constant (someday we might want to change that), but at least it's a different constant for each SLRU area. Increase number of subtrans buffers to 32 based on experimentation with a heavily subtrans-bashing test case, and increase number of multixact member buffers to 16, since it's obviously silly for it not to be at least twice the number of multixact offset buffers.
2005-12-06Add documentation on the use of *printf() macros and libintl.Bruce Momjian
Backpatch to 8.1.X.
2005-12-06Arrange for read-only accesses to SLRU page buffers to take only a sharedTom Lane
lock, not exclusive, if the desired page is already in memory. This can be demonstrated to be a significant win on the pg_subtrans cache when there is a large window of open transactions. It should be useful for pg_clog as well. I didn't try to make GetMultiXactIdMembers() use the code, as that would have taken some restructuring, and what with the local cache for multixact contents it probably wouldn't really make a difference. Per my recent proposal.
2005-12-06In a nestloop inner indexscan, it's OK to use pushed-down baserestrictinfoTom Lane
clauses even if it's an outer join. This is a corner case since such clauses could only arise from weird OUTER JOIN ON conditions, but worth fixing. Per example from Ron at cheapcomplexdevices.com.
2005-12-06ecpg/pgtypeslib seems to need snprintf.c pulled in, too.Tom Lane
2005-12-06Put undef's before extern declarations that need 'em, per Andrew Dunstan.Tom Lane
2005-12-06Make Win32 build use our port/snprintf.c routines, instead of dependingTom Lane
on libintl which may or may not provide what we need. Make a few marginal cleanups to ensure this works. Andrew Dunstan and Tom Lane.
2005-12-05Document return-value conventions used by this implementation, perTom Lane
suggestion from Bruce.
2005-12-05Add regression test to see if the min/max values of int8 convert correctly.Tom Lane
2005-12-05Fix a rather sizable number of problems in our homegrown snprintf, such asTom Lane
incorrect implementation of argument reordering, arbitrary limit of output size for sprintf and fprintf, willingness to access more bytes than "%.Ns" specification allows, wrong formatting of LONGLONG_MIN, various field-padding bugs and omissions. I believe it now accurately implements a subset of the Single Unix Spec requirements (remaining unimplemented features are documented, too). Bruce Momjian and Tom Lane.
2005-12-03Treat procedural languages as owned by the bootstrap superuser, ratherTom Lane
than owned by nobody. This results in cleaner display of language ACLs, since the backend's aclchk.c uses the same convention. AFAICS there is no practical difference but it's nice to avoid emitting SET SESSION AUTHORIZATION; also this will make it easier to transition pg_dump to some future version in which we may include an explicit ownership column in pg_language. Per gripe from David Begley.
2005-12-03Fix out-of-order inclusion of -L switches from LDFLAGS on AIX and HPUX.Tom Lane
Per example from Dirk Pirschel.
2005-12-03Allow to_char(interval) and to_char(time) to use AM/PM specifications.Bruce Momjian
Map them to a single day, so '30 hours' is 'AM'. Have to_char(interval) and to_char(time) use "HH", "HH12" as 12-hour intervals, rather than bypass and print the full interval hours. This is neeeded because to_char(time) is mapped to interval in this function. Intervals should use "HH24", and document suggestion. Allow "D" format specifiers for interval/time.
2005-12-03Tweak indexscan machinery to avoid taking an AccessShareLock on an indexTom Lane
if we already have a stronger lock due to the index's table being the update target table of the query. Same optimization I applied earlier at the table level. There doesn't seem to be much interest in the more radical idea of not locking indexes at all, so do what we can ...
2005-12-02Fix obsolete comment.Tom Lane
2005-12-02Adjust scan plan nodes to avoid getting an extra AccessShareLock on aTom Lane
relation if it's already been locked by execMain.c as either a result relation or a FOR UPDATE/SHARE relation. This avoids an extra trip to the shared lock manager state. Per my suggestion yesterday.
2005-12-02Added special handling of CONNECTION variable that is used by ECPG instead ↵Michael Meskes
of given to the backend.
2005-12-02Remove comment on errno=0 lines, but add mention to port/strtol.c function.Bruce Momjian
2005-12-02Rearrange code in ExecInitBitmapHeapScan so that we don't initialize theTom Lane
child plan nodes until we have acquired lock on the relation to scan. The relative order of initialization of plan nodes isn't real important in other cases, but it's critical here because one is supposed to lock a relation before its indexes, not vice versa. The original coding was at least vulnerable to deadlock against DROP INDEX, and perhaps worse things.
2005-12-01Add comment to pg_atoi.Bruce Momjian
2005-12-01Comment "errno = 0" in a more generic way.Bruce Momjian
2005-12-01Retry in FileRead and FileWrite if Windows returns ERROR_NO_SYSTEM_RESOURCES.Tom Lane
Also add a retry for Unixen returning EINTR, which hasn't been reported as an issue but at least theoretically could be. Patch by Qingqing Zhou, some minor adjustments by me.