Commit Graph

1884 Commits

Author SHA1 Message Date
Marc G. Fournier c5a27161a1 More cleanups ... this is one big file *sigh* 1998-12-15 04:00:46 +00:00
Marc G. Fournier 3b8854ff93 Correct some typos... 1998-12-15 02:32:57 +00:00
Marc G. Fournier c1bc907f01 More cleanups of appendStringInfo() function calls... 1998-12-15 02:24:15 +00:00
Marc G. Fournier 9396802f14 more cleanups...of note, appendStringInfo now performs like sprintf(),
where you state a format and arguments.  the old behavior required
each appendStringInfo to have to have a sprintf() before it if any
formatting was required.

Also shortened several instances where there were multiple appendStringInfo()
calls in a row, doing nothing more then adding one more word to the String,
instead of doing them all in one call.
1998-12-14 08:11:17 +00:00
Marc G. Fournier df1468e251 Many more cleanups... 1998-12-14 06:50:32 +00:00
Marc G. Fournier 7c3b7d2744 Initial attempt to clean up the code...
Switch sprintf() to snprintf()
Remove any/all #if 0 -or- #ifdef NOT_USED -or- #ifdef FALSE sections of
	code
1998-12-14 05:19:16 +00:00
Bruce Momjian ffb90a01fd Current multi-byte related codes have a bug with SQL_ASCII
support. Included patches will solve it and should be applied to
both trees.  Also, it fix the problem with \c command of psql when
switching different encoding databases.

Regression tests passed.
--
Tatsuo Ishii
t-ishii@sra.co.jp
1998-12-14 04:59:58 +00:00
Thomas G. Lockhart 4140c2f30e Add support for the CASE statement in the rewrite handling.
Allows (at least some) rules and views.
Still some trouble (crashes) with target CASE columns spanning tables,
 but lots now works.
1998-12-14 00:02:17 +00:00
Thomas G. Lockhart 2b189aa953 Improve CASE statement support.
Try to label CASE columns for a SELECT if not specified with an AS clause.
1998-12-13 23:56:44 +00:00
Thomas G. Lockhart 44cf948467 Fix up error messages when looking up functions and operators to not
make the sometimes misleading claim that more than one candidate was
 identified. Now say "Unable to identify...".
1998-12-13 23:54:40 +00:00
Thomas G. Lockhart 1a8790f7eb Use the new implicit type coersion techniques for matching up types
between columns and DEFAULT clauses.
1998-12-13 23:50:58 +00:00
Thomas G. Lockhart 239564e9ef Add routines to help with single-byte (internal) character type support. 1998-12-13 23:36:48 +00:00
Thomas G. Lockhart f9f4004b7c Switch around conditional code so that HAVE_TM_ZONE takes precedence
over HAVE_INT_TIMEZONE. This may help out linux/glibc2 and Dec Alpha.
Included #error precompiler macros to catch cases where neither is defined
 but USE_POSIX_TIME is (shouldn't happen). Hopefully this isn't just
 a gcc-ism.
1998-12-13 23:34:17 +00:00
Bruce Momjian afded8add3 Fix for lo_import crash. 1998-12-13 05:07:50 +00:00
Bruce Momjian 31d825ba07 While investigating a user's complaint, I have found some memory
destructions in 6.4 source using purify.

(1) parser/gram.y:fmtId()

It writes n+3 bytes into n+1 byte-long memory area if mixed case or
non-ascii identifiers given.

(2) catalog/index.c:

ATTRIBUTE_TUPLE_SIZE bytes are allocated but
sizeof(FormData_pg_attribute) bytes are written. Note that
ATTRIBUTE_TUPLE_SIZE is smaller than
sizeof(FormData_pg_attribute). (for example, on solaris 2.6,

Tatsuo Ishii
1998-12-13 04:37:51 +00:00
Bruce Momjian 589f5aa241 I have a simple patch about the treatment of functions.
But it may be self-satisfied.
Please check my patch at the end of this posting.

Case 1. executor evaluates functions twice

Hiroshi Inoue
Inoue@tpf.co.jp
1998-12-13 04:16:51 +00:00
Bruce Momjian 5c431eb1f2 Included patches should fix following problems in the muti-byte
enabled PostgreSQL 6.4.

o binary cursor does not work
o pg_dumpall produces incorrect create database statemnt

Tatsuo Ishii
t-ishii@sra.co.jp
1998-12-12 22:04:09 +00:00
Bruce Momjian 439ef85b0d Fix prototype for 64-bit platforms. 1998-12-12 21:30:57 +00:00
Bruce Momjian 0d5a08f769 Add stdio for NULL define. 1998-12-12 19:57:51 +00:00
Thomas G. Lockhart 53b476798a Define routines and catalog entries for string min()/max() functions.
Extend new type coersion techniques to aggregates.
Clean up a few elog() messages.
1998-12-08 06:19:15 +00:00
Thomas G. Lockhart bedd04a551 Implement CASE expression. 1998-12-04 15:34:49 +00:00
Tom Lane 92eacaf523 Change exp() behavior to generate error on underflow rather
than silently returning zero on some machines.  Correct float8 regress test
to agree.  Also fix pow() overflow/underflow check to work correctly on
HPUX.
1998-11-29 01:57:59 +00:00
Tom Lane 79fcde48b2 Portability fix for old SunOS releases: fflush(NULL)
doesn't work there.  Fortunately the postmaster only has stdout and
stderr to flush.
1998-11-29 01:51:56 +00:00
Tom Lane 9e0e148a83 pq_getstr didn't handle buffer overrun correctly; it would
fail to consume the rest of the input string, and worse it would write
one more byte than it should into the buffer, probably resulting in coredump.
Fortunately there's a correct implementation next door in pqcomprim.c.
1998-11-29 01:47:42 +00:00
Vadim B. Mikheev 6beba218d7 New HeapTuple structure/interface. 1998-11-27 19:52:36 +00:00
Vadim B. Mikheev 34680930d5 Fix using indices in OR.
EXPLAIN all indices used.
1998-11-22 10:48:45 +00:00
Thomas G. Lockhart 643c7beddf Add text<->float8 and text<->float4 conversion functions.
This will fix the problem reported by Jose' Soares
 when trying to cast a float to text.
1998-11-17 14:36:51 +00:00
Thomas G. Lockhart 8d507c204b Additional fixes for mixed-case table names from Billy Allie. 1998-11-17 14:26:39 +00:00
Thomas G. Lockhart 2795fae5bf Fix test for table existance to allow mixed-case and whitespace in
the table name. Problem reported by Billy Allie.
1998-11-12 15:39:06 +00:00
Bruce Momjian f03729c621 Fix for NOT in where clause causing crash. 1998-11-09 02:49:13 +00:00
Tom Lane 39792e5b01 EXPLAIN VERBOSE had a very high probability of triggering
a backend core dump, because it was concatenating a potentially long
string onto another string that didn't necessarily have enough room.
Shame, shame.
1998-11-08 19:38:34 +00:00
Tom Lane 8f5ff4cf1c Fix a potential infinite loop in appendStringInfo: would lock
up if first string to be appended to an empty StringInfo was longer
than the initial space allocation.
Also speed it up slightly.
1998-11-08 19:22:24 +00:00
Bruce Momjian 733ad60409 Fix for relname.data from SHIOZAKI Takehiko 1998-11-02 15:28:36 +00:00
Marc G. Fournier 4283089d07 Okay, this shoudl provide a fix for the freebsd problem...
Added a ELF_SYS variable and check to configure.in...
1998-10-30 04:54:06 +00:00
Thomas G. Lockhart 396571d79c Very minor cleanup of no-op code. 1998-10-29 18:11:28 +00:00
Bruce Momjian 1e7c7343c4 Add oid8neq. 1998-10-29 18:07:09 +00:00
Tom Lane 9e38dcfd43 Re-fix test for negative-integer return code that should be
testing for null-pointer return code...
1998-10-29 16:13:07 +00:00
Bruce Momjian 374d9a1f2b D'Arcy INET fix. 1998-10-29 04:41:44 +00:00
Tom Lane a787b88e3c Eliminate need for cpp-from-stdin by using a temp file. 1998-10-28 19:38:47 +00:00
Bruce Momjian 53b8ea58d3 Fix for serial creation. 1998-10-28 16:06:54 +00:00
Bruce Momjian 8386c8145c Reverse out addition of snprintf. 1998-10-28 02:57:59 +00:00
Marc G. Fournier 8107299d5e Don't forget to create the dynloader files... 1998-10-27 04:41:29 +00:00
Bruce Momjian 7825f9b890 Fix for tprintf overruns from Göran Thyni. 1998-10-27 03:26:48 +00:00
Tom Lane 990fa43c23 Get rid of some minor compiler warnings. 1998-10-26 01:05:07 +00:00
Tom Lane 0bdf46a37f Fix some actual bugs exposed by compiler warnings.
(Someone forgot whether their subroutine signaled errors by a NULL pointer
return value, or a negative integer... I'm surprised gcc -Wall doesn't
catch this...)
1998-10-26 01:03:24 +00:00
Tom Lane 3d87216ab9 Get rid of some minor compiler warnings.
(HP's cc doesn't like if you forward-declare a routine static,
and then don't make it static in the actual definition...)
1998-10-26 01:00:13 +00:00
Bruce Momjian 54fd5f6cc4 Fix from Jan for vacuum statistics loss. 1998-10-23 16:49:24 +00:00
Bruce Momjian 1115162c84 rename file. 1998-10-23 02:56:13 +00:00
Bruce Momjian aeb277c405 Update for bsdi 3.0. 1998-10-23 01:02:10 +00:00
Bruce Momjian 33c4072dbc INET/CIDR cleanup from D'Arcy. 1998-10-22 20:40:50 +00:00