Tom Lane [Fri, 19 Mar 2004 02:23:59 +0000 (02:23 +0000)]
Code review for log_line_prefix patch. Cooperate with StringInfo instead
of fighting it, avoid hard-wired (and wrong) assumption about max length
of prefix, cause %l to actually work as documented, don't compute data
we may not need.
Bruce Momjian [Thu, 18 Mar 2004 23:27:29 +0000 (23:27 +0000)]
Make test_fsync use optimizer flag.
Bruce Momjian [Thu, 18 Mar 2004 23:26:17 +0000 (23:26 +0000)]
Fix log_executor_stats if() test.
Bruce Momjian [Thu, 18 Mar 2004 23:23:58 +0000 (23:23 +0000)]
Add Unixware thread support from Larry Rosenman.
Bruce Momjian [Thu, 18 Mar 2004 20:09:33 +0000 (20:09 +0000)]
Allocate 16mb file for testing.
Bruce Momjian [Thu, 18 Mar 2004 19:54:00 +0000 (19:54 +0000)]
Have program default to 1000 loops, and add file name and loop option.
Make open/close loop testings the same. Add descriptions for certain tests.
Bruce Momjian [Thu, 18 Mar 2004 17:23:56 +0000 (17:23 +0000)]
Add comment about using this testing for wal_sync_method.
Bruce Momjian [Thu, 18 Mar 2004 15:26:27 +0000 (15:26 +0000)]
Add fsync tests:
Compare fsync before and after write's close:
Compare one o_sync write to two:
Compare file sync methods with one 8k write:
Compare file sync methods with 2 8k writes:
Bruce Momjian [Thu, 18 Mar 2004 14:02:58 +0000 (14:02 +0000)]
Mention which fsync methods are unavailable.
Bruce Momjian [Thu, 18 Mar 2004 04:11:41 +0000 (04:11 +0000)]
Add permission mode to opens().
Bruce Momjian [Thu, 18 Mar 2004 04:04:36 +0000 (04:04 +0000)]
Add missing include
Bruce Momjian [Thu, 18 Mar 2004 03:57:58 +0000 (03:57 +0000)]
Remove acccidental object/binary files.
Bruce Momjian [Thu, 18 Mar 2004 03:56:59 +0000 (03:56 +0000)]
Add fsync test program. It tests fsync to see if times for fsync are the
same when done on the write() ile descriptor and a new descriptor.
it also times various fsync methods.
Bruce Momjian [Wed, 17 Mar 2004 22:30:10 +0000 (22:30 +0000)]
Done:
> * -Order duplicate index entries on creation by tid for faster heap lookups
Tom Lane [Wed, 17 Mar 2004 22:24:58 +0000 (22:24 +0000)]
During btree index build, sort equal-keyed tuples according to their
TID (heap position). This doesn't do anything to the validity of the
finished index, but by pretending to qsort() that there are no really
equal keys in the sort, we can avoid performance problems with qsort
implementations that have trouble with large numbers of equal keys.
Patch from Manfred Koizar.
Tom Lane [Wed, 17 Mar 2004 20:48:43 +0000 (20:48 +0000)]
Reimplement CASE val WHEN compval1 THEN ... WHEN compval2 THEN ... END
so that the 'val' is computed only once, per recent discussion. The
speedup is not much when 'val' is just a simple variable, but could be
significant for larger expressions. More importantly this avoids issues
with multiple evaluations of a volatile 'val', and it allows the CASE
expression to be reverse-listed in its original form by ruleutils.c.
Bruce Momjian [Wed, 17 Mar 2004 17:40:44 +0000 (17:40 +0000)]
Modify:
< * Order duplicate index entries by tid for faster heap lookups
> * Order duplicate index entries on creation by tid for faster heap lookups
Bruce Momjian [Wed, 17 Mar 2004 01:05:10 +0000 (01:05 +0000)]
Document SPI_push() and SPI_pop().
Tom Lane [Wed, 17 Mar 2004 01:02:24 +0000 (01:02 +0000)]
Replace the switching function ExecEvalExpr() with a macro that jumps
directly to the appropriate per-node execution function, using a function
pointer stored by ExecInitExpr. This speeds things up by eliminating one
level of function call. The function-pointer technique also enables further
small improvements such as only making one-time tests once (and then
changing the function pointer). Overall this seems to gain about 10%
on evaluation of simple expressions, which isn't earthshaking but seems
a worthwhile gain for a relatively small hack. Per recent discussion
on pghackers.
Bruce Momjian [Tue, 16 Mar 2004 16:13:38 +0000 (16:13 +0000)]
Add:
> * Allow pg_dumpall to use non-text output formats
>
Bruce Momjian [Tue, 16 Mar 2004 05:05:58 +0000 (05:05 +0000)]
Remove double-rename used by Win32 on busy files. Not needed anymore.
Bruce Momjian [Mon, 15 Mar 2004 17:57:51 +0000 (17:57 +0000)]
log_statement was not removed by the previous patch. It only updated
its description.
Bruce Momjian [Mon, 15 Mar 2004 16:27:43 +0000 (16:27 +0000)]
The "cvs add" of test_thread_implicit.pgc seems to have been missed,
i've attached this again.
Additionally I include a small patch to remove mutex locking when a
DEFAULT/NULL connection is being retrieved. This is consistent with
libpq.
Lee Kindness
Bruce Momjian [Mon, 15 Mar 2004 16:21:37 +0000 (16:21 +0000)]
Check for EOF on pipe differs under win32, as it is based on a socket
implementation.
Claudio Natoli
Bruce Momjian [Mon, 15 Mar 2004 16:20:52 +0000 (16:20 +0000)]
float8-small-is-zero and float8-exp-three-digits will likely need
similar changes.
Claudio Natoli
Bruce Momjian [Mon, 15 Mar 2004 16:18:43 +0000 (16:18 +0000)]
* postc: cleanup pmdaemonize under win32; missed failure message
in CreateOptsFile
* s_lock.c: minor comment fix
* findbe.c: variables not used under win32 moved within #ifndef WIN32
case
Claudio Natoli
Bruce Momjian [Mon, 15 Mar 2004 16:17:30 +0000 (16:17 +0000)]
Handle OID's and unsigned values better in pg_autovacuum.
Matthew T. O'Connor
Bruce Momjian [Mon, 15 Mar 2004 16:14:26 +0000 (16:14 +0000)]
Windows uses codepages rather than the environment, so we work around
that by querying the environment explicitly first for LC_COLLATE and
LC_CTYPE. We have to do this because initdb passes those values in the
environment. If there is nothing there we fall back on the codepage.
Andrew Dunstan
Bruce Momjian [Mon, 15 Mar 2004 16:11:42 +0000 (16:11 +0000)]
Update random regression test text to be clearer.
Bruce Momjian [Mon, 15 Mar 2004 16:06:43 +0000 (16:06 +0000)]
Update random test description because it fails less frequently now.
Bruce Momjian [Mon, 15 Mar 2004 15:56:28 +0000 (15:56 +0000)]
Remove GUC log_statement, log_pid, log_timestamp, log_source_port.
Functionality superceeded by log_line_prefix.
Andrew Dunstan
Bruce Momjian [Mon, 15 Mar 2004 15:46:25 +0000 (15:46 +0000)]
Improve random regression tests to fail less frequently.
Bruce Momjian [Mon, 15 Mar 2004 14:21:30 +0000 (14:21 +0000)]
Fix typo.
Bruce Momjian [Mon, 15 Mar 2004 14:15:45 +0000 (14:15 +0000)]
Mention Linux syslog will sync lines to disk, and describe how to
disable it.
Tatsuo Ishii [Mon, 15 Mar 2004 10:41:26 +0000 (10:41 +0000)]
Add PQmbdsplen() which returns the "display length" of a character.
Still some works needed:
- UTF-8, MULE_INTERNAL always returns 1
Tom Lane [Mon, 15 Mar 2004 03:29:22 +0000 (03:29 +0000)]
Localize our dependencies on the way to create NAN or INFINITY.
Per recent proposal to pghackers.
Tom Lane [Mon, 15 Mar 2004 01:13:41 +0000 (01:13 +0000)]
Remove grotty special-case code in coerce_to_target_type() that
implemented casts to varchar and bpchar using a cast-to-text function.
This is a holdover from before we had pg_cast; it now makes more sense
to just list these casts in pg_cast. While at it, add pg_cast entries
for the other direction (casts from varchar/bpchar) where feasible.
Bruce Momjian [Sun, 14 Mar 2004 23:51:48 +0000 (23:51 +0000)]
Update Solaris thread flags, per Jim Seymour
Tom Lane [Sun, 14 Mar 2004 23:41:27 +0000 (23:41 +0000)]
Tweak planner so that index expressions and predicates are matched to
queries without regard to whether coercions are stated explicitly or
implicitly. Per suggestion from Stephan Szabo.
Tom Lane [Sun, 14 Mar 2004 22:00:54 +0000 (22:00 +0000)]
Fix error in termination of COPY IN mode when using V2 protocol.
Report and fix per ljb, 8-Mar-04.
Bruce Momjian [Sun, 14 Mar 2004 15:06:13 +0000 (15:06 +0000)]
Mark linux as thread-enabled with new 7.5 tests.
Bruce Momjian [Sun, 14 Mar 2004 14:47:33 +0000 (14:47 +0000)]
Fix ecpg_sqlca_key_destructor to return void.
Bruce Momjian [Sun, 14 Mar 2004 14:01:43 +0000 (14:01 +0000)]
> (I also see some post-7.4.1 changes in src/template/solaris, so you
> possibly should look there too.)
[snip]
>
I think I have the fix for part of it, but this remains...
gcc -O2 -fno-strict-aliasing -Wall -Wmissing-prototypes
-Wmissing-declarations -fPIC -I. -I../../../src/include
-D_POSIX_PTHREAD_SEMANTICS -DFRONTEND
-DSYSCONFDIR='"/usr/local/pgsql/etc"' -c -o thread.o thread.c
thread.c: In function `pqGethostbyname':
thread.c:189: error: `resbuf' undeclared (first use in this
function)
Looking at src/port/thread.c, line 189, it looks like somebody typo'd.
Looks like that second parameter should be "resultbuf", not "resbuf"?
Jim Seymour
Michael Meskes [Sun, 14 Mar 2004 12:16:30 +0000 (12:16 +0000)]
- Fixed Informix compat math functions to cope with the situations
where one argument takes the result.
- Applied thread patches by Lee Kindness
Neil Conway [Sun, 14 Mar 2004 05:22:52 +0000 (05:22 +0000)]
Portability fixes and bug fixes for recent floating point input changes.
In particular, don't depend on strtod() to accept 'NaN' and 'Infinity'
inputs (while this is required by C99, not all platforms are compliant
with that yet). Also, don't require glibc's behavior from isinf():
it seems that on a lot of platforms isinf() does not itself distinguish
between negative and positive infinity.
Tom Lane [Sun, 14 Mar 2004 04:25:18 +0000 (04:25 +0000)]
Teach psql to show the location of syntax errors visually, per recent
discussions. Patch by Fabien Coelho and Tom Lane. Still needs to be
taught about multi-screen-column kanji characters; Tatsuo has promised
to provide the needed infrastructure for that.
Bruce Momjian [Sun, 14 Mar 2004 03:19:13 +0000 (03:19 +0000)]
Rename README's to match directory names. Mention copyright matches
PostgreSQL's.
Tom Lane [Sun, 14 Mar 2004 01:58:41 +0000 (01:58 +0000)]
Arrange to emit a CONTEXT: SQL function "foo" entry in an error
message that is reporting a prechecking error in a SQL function.
This is to cue client-side code that the syntax error position,
if any, is with respect to the function body and not the outer command.
Bruce Momjian [Sat, 13 Mar 2004 23:17:39 +0000 (23:17 +0000)]
Done:
> * -Issue NOTICE if foreign key data requires costly test to match primary key
Tom Lane [Sat, 13 Mar 2004 22:09:14 +0000 (22:09 +0000)]
Generate a WARNING when the column types in a foreign key constraint are
incompatible enough to prevent indexscanning the referenced table. Also,
improve the error message that pops out when we can't implement the FK at
all for lack of a usable equality operator. Fabien Coelho, with some review
by Tom Lane.
Tom Lane [Sat, 13 Mar 2004 00:54:10 +0000 (00:54 +0000)]
Repair memory leakage introduced into the non-hashed aggregate case by
7.4 rewrite for hashed aggregate support. If the transition data type
is pass-by-reference, the transValue must be pfreed when starting a new
group boundary, else we have a one-value-per-group leakage. Thanks to
Rae Steining for providing a reproducible test case.
Dennis Bjorklund [Fri, 12 Mar 2004 18:32:51 +0000 (18:32 +0000)]
Translation updates
Bruce Momjian [Fri, 12 Mar 2004 14:08:05 +0000 (14:08 +0000)]
Fixes recent changes to test. For immediate application.
[ Note: int8-exp-three-digits.out needs the same treatment]
Will review recent changes for float4/8 and implications for win32 when
I get a chance.
Claudio Natoli
Bruce Momjian [Fri, 12 Mar 2004 13:51:57 +0000 (13:51 +0000)]
Update FAQ with current release version.
Bruce Momjian [Fri, 12 Mar 2004 13:51:33 +0000 (13:51 +0000)]
Update Russian FAQ, Viktor Vislobokov
Dennis Bjorklund [Fri, 12 Mar 2004 12:59:09 +0000 (12:59 +0000)]
Translation updates
Dennis Bjorklund [Fri, 12 Mar 2004 12:38:36 +0000 (12:38 +0000)]
Translation updates
Bruce Momjian [Fri, 12 Mar 2004 04:33:41 +0000 (04:33 +0000)]
Rename incorrect references to nonblock.c to noblock.c. Claudio.
Neil Conway [Fri, 12 Mar 2004 00:56:00 +0000 (00:56 +0000)]
Fix a typo in the documentation for geqo_effort.
Neil Conway [Fri, 12 Mar 2004 00:52:23 +0000 (00:52 +0000)]
Improve documentation for the newly-added NOWAIT clause of LOCK TABLE.
Neil Conway [Fri, 12 Mar 2004 00:25:43 +0000 (00:25 +0000)]
Allow 'Infinity' and '-Infinity' as input to the float4 and float8
types. Update the regression tests and the documentation to reflect
this. Remove the UNSAFE_FLOATS #ifdef.
This is only half the story: we still unconditionally reject
floating point operations that result in +/- infinity. See
recent thread on -hackers for more information.
Dennis Bjorklund [Thu, 11 Mar 2004 15:48:57 +0000 (15:48 +0000)]
Translation updates
Bruce Momjian [Thu, 11 Mar 2004 02:39:10 +0000 (02:39 +0000)]
Document the SSL and Kerberos are not thread-safe.
Neil Conway [Thu, 11 Mar 2004 02:11:14 +0000 (02:11 +0000)]
Revise int2/int4/int8/float4/float8 input routines to allow for
any amount of leading or trailing whitespace (where "whitespace"
is defined by isspace()). This is for SQL conformance, as well
as consistency with other numeric types (e.g. oid, numeric).
Also refactor pg_atoi() to avoid looking at errno where not
necessary, and add a bunch of regression tests for the input
to these types.
Tatsuo Ishii [Thu, 11 Mar 2004 01:47:41 +0000 (01:47 +0000)]
Add NOWAIT option to LOCK command
Bruce Momjian [Wed, 10 Mar 2004 21:12:49 +0000 (21:12 +0000)]
Move non-blocking code into its own /port file, for code clarity.
Neil Conway [Wed, 10 Mar 2004 20:10:26 +0000 (20:10 +0000)]
Fix a typo.
Neil Conway [Wed, 10 Mar 2004 01:31:15 +0000 (01:31 +0000)]
Improvements to README.CVS
Bruce Momjian [Wed, 10 Mar 2004 00:28:11 +0000 (00:28 +0000)]
Remove HISTORY and INSTALL. Have them generated by the tarball scripts.
Add README.CVS to help CVS folks find this information.
Neil Conway [Tue, 9 Mar 2004 23:15:47 +0000 (23:15 +0000)]
Tweak some text to avoid using <command>SET</command> as a verb, per
suggestion from Peter E.
Bruce Momjian [Tue, 9 Mar 2004 22:40:10 +0000 (22:40 +0000)]
Add comment for Win32.
Bruce Momjian [Tue, 9 Mar 2004 20:10:10 +0000 (20:10 +0000)]
Remove blank line in Makefile.
Bruce Momjian [Tue, 9 Mar 2004 20:08:10 +0000 (20:08 +0000)]
Add HISTORY/INSTALL clean target to 7.4.X.
Peter Eisentraut [Tue, 9 Mar 2004 19:47:05 +0000 (19:47 +0000)]
Build scanner output when making a distribution.
Neil Conway [Tue, 9 Mar 2004 19:30:21 +0000 (19:30 +0000)]
Add documentation for the recent 'ALSO' patch for CREATE RULE. Along
the way, fix a typo and make a few SGML cleanups.
Bruce Momjian [Tue, 9 Mar 2004 17:40:27 +0000 (17:40 +0000)]
Rebuild HISTORY file to match our official style sheets.
Neil Conway [Tue, 9 Mar 2004 16:57:47 +0000 (16:57 +0000)]
Refer to GUC variables using <xref> tags rather than <varname> tags,
where appropriate. Add "id" and "xreflabel" tags to the descriptions
of the GUC variables to facilitate this. Also make a few minor docs
cleanups.
Bruce Momjian [Tue, 9 Mar 2004 05:11:53 +0000 (05:11 +0000)]
Corrects a typo, introduces missing variables, and rearranges the
initialization of stats process under EXEC_BACKEND.
[A cleaner, rationalized approach to stat/backend/SSDataBase child
processes under EXEC_BACKEND is on my TODO list. However this patch
takes care of immediate concerns (ie. stats test now passes under
win32)]
Claudio Natoli
Bruce Momjian [Tue, 9 Mar 2004 05:06:45 +0000 (05:06 +0000)]
Determines the PKGLIBDIR equivalent under win32. Requires pgsql lib and
bin directories to be packaged under the same root directory (eg. <some
path>/pgsql/bin and <some path>/pgsql/lib) for the win32 port, which
does not appear to be an onerous restriction.
Claudio Natoli
Bruce Momjian [Tue, 9 Mar 2004 05:05:41 +0000 (05:05 +0000)]
Add ALSO keyword to CREATE RULE.
Fabien COELHO
Bruce Momjian [Tue, 9 Mar 2004 04:53:37 +0000 (04:53 +0000)]
Make a separate win32 debug DLL along with the non-debug version:
Currently, src/interfaces/libpq/win32.mak builds a statically-linked
library "libpq.lib", a debug dll "libpq.dll", import library for the
debug dll "libpqdll.lib", a release dll "libpq.dll", import library for
the release dll "libpqdll.lib". To avoid naming clashes, I would make
the debug dll and import libraries "libpqd.dll" and "libpqddll.lib".
Basically, the debug build uses the cl flags: "/MDd /D _DEBUG", and the
release build uses the cl flags "/MD /D NDEBUG". Usually the debug
build has a "D" suffix on the file name, so for example:
libpqd.dll libpq, debug build
libpqd.lib libpq, debug build, import library
libpq.dll libpq, release build
libpq.lib libpq, release build, import library
David Turner
Bruce Momjian [Tue, 9 Mar 2004 04:49:02 +0000 (04:49 +0000)]
The win32 port backend will require the functionality provided by
canonicalize_path. Patch moves it from initdb.c to port/path.c.
Claudio Natoli
Bruce Momjian [Tue, 9 Mar 2004 04:45:48 +0000 (04:45 +0000)]
Done:
> * -Allow log lines to include session-level information, like database and user
Bruce Momjian [Tue, 9 Mar 2004 04:43:07 +0000 (04:43 +0000)]
Add:
#log_line_prefix = '' # e.g. '<%u%%%d> '
# %u=user name %d=database name
# %r=remote host and port
# %p=PID %t=timestamp %i=command tag
# %c=session id %l=session line number
# %s=session start timestamp
# %x=stop here in non-session processes
# %%='%'
Andrew Dunstan
Bruce Momjian [Tue, 9 Mar 2004 01:59:13 +0000 (01:59 +0000)]
I wanted to submit some changes to the bundled postgres startup
script for Mac OS X. I added calls to utilize the bundled apache
rotatelogs script in the DB startup for log rotation. Also modified
startup parameters file to allow using the "SystemStarter" utility to
start/stop/restart postgres with a rotating log file.
The script credits David Wheeler, 2002. I wrote him a message about
the changes an he suggested I post them here. I explain some of the
changes below.
Not sure how to submit the changes. I have 3 files, "PostgreSQL"
script, "StartupParameters.plist" file, "pg_startupscript.diff" file.
The diff file was run against the original "PostgreSQL" script file.
I'll try attaching them to this message. If they get filtered I can
resend if needed.
Thanks.
Ray A.
------------------------------------
1) Changed the "Provides" parameter in StartupParameters.plist to
"PostgreSQL" from "postgres database" simply for ease of typing. It
seems that the SystemStarter utility uses the "Provides" value if you
want to control the script. This way I did not have to enclose it in
quotes on commandline. The modified StartupParameters.plist is now an
XML document also.
2) For the startup script I added 2 user modifiable variables:
# do you want to rotate the log files, 1=true 0=false
ROTATELOGS=1
# logfile rotate in seconds
ROTATESEC="604800"
I also added a non modifiable variable:
# The apache log rotation utility
LOGUTIL="/usr/sbin/rotatelogs"
I modified the StartService and RestartService functions to execute
the new commands if the user wants log rotation.
Ray Aspeitia
Bruce Momjian [Mon, 8 Mar 2004 23:59:23 +0000 (23:59 +0000)]
Have SGML make clean remove text files output as well
Bruce Momjian [Mon, 8 Mar 2004 21:35:59 +0000 (21:35 +0000)]
Add comment about why ON COMMENT in non-current database throws just an
warning.
Bruce Momjian [Mon, 8 Mar 2004 17:38:31 +0000 (17:38 +0000)]
Update German FAQ.
Ian Barwick
Tom Lane [Mon, 8 Mar 2004 17:20:17 +0000 (17:20 +0000)]
Test for whether a previous IN join restricts the current join was too
strict, per discussion with Dennis Haney.
Also, rearrange the preceding tests to avoid redundancy.
Tom Lane [Sun, 7 Mar 2004 22:07:56 +0000 (22:07 +0000)]
Some editorial work on 7.4.2 release notes.
Neil Conway [Sun, 7 Mar 2004 20:41:27 +0000 (20:41 +0000)]
contrib/xml2 updates from John Gray:
I have changed the name of the new parse function to xml_valid and fixed
a reference to SortMem which meant that the code as supplied would work
against 7.3 and 7.4 but wouldn't work in CVS.
Michael Meskes [Sun, 7 Mar 2004 14:35:47 +0000 (14:35 +0000)]
Added multidimensional arrays as todo for ecpg.
Tom Lane [Sun, 7 Mar 2004 05:43:53 +0000 (05:43 +0000)]
When testing usability of a partial index, recognize that an index
predicate of the form 'foo IS NOT NULL' is implied by a WHERE clause
that uses 'foo' in any strict operator or function. Per suggestion
and preliminary implementation by John Siracusa; some further hacking
by moi.
Neil Conway [Sun, 7 Mar 2004 04:31:01 +0000 (04:31 +0000)]
Improve discussion of using OIDs for identifying rows, fix an instance of
incorrect SGML markup.
Joe Conway [Sun, 7 Mar 2004 02:27:00 +0000 (02:27 +0000)]
Added new versions of dblink, dblink_exec, dblink_open, dblink_close,
and, dblink_fetch -- allows ERROR on remote side of connection to
throw NOTICE locally instead of ERROR. Also removed documentation for
previously deprecated, now removed, functions.
Neil Conway [Sun, 7 Mar 2004 01:02:55 +0000 (01:02 +0000)]
Explicitely mention that some GUC variables cannot be changed at
runtime.
Neil Conway [Sun, 7 Mar 2004 01:01:44 +0000 (01:01 +0000)]
Editorialization of some text discussing 'IS NULL' vs. '= NULL'.
Bruce Momjian [Sat, 6 Mar 2004 02:52:46 +0000 (02:52 +0000)]
Use lynx -stdin and regenerate HISTORY
Tom Lane [Fri, 5 Mar 2004 23:16:17 +0000 (23:16 +0000)]
Improve documentation of virtual_host parameter: old text failed to
indicate that you could specify multiple listen addresses.
Bruce Momjian [Fri, 5 Mar 2004 20:01:46 +0000 (20:01 +0000)]
Have makefile reference /xml2.