Commit Graph

1403 Commits

Author SHA1 Message Date
Marc G. Fournier 7c82b2e9c3 From: Thomas Lockhart <Thomas.G.Lockhart@jpl.nasa.gov>
Subject: [PATCHES] date/time timezone patches (mail bounced?)

Here are some hacks to get timezone behavior for the various time
data types to be compatible with v6.0. Although we have some hooks
already installed to get timezone info from the client to the
server, it still isn't clear if that can correctly transfer enough
timezone info to make the behavior the same as if timezone info
were derived from the server as is now the case. We certainly
won't resolve it in a day, so I think we are stuck with server-only
timezones for v6.1.
1997-04-22 17:36:57 +00:00
Marc G. Fournier 9e2a87b62d Major patch from Thomas Lockhart <Thomas.G.Lockhart@jpl.nasa.gov>
OK, here are a passel of patches for the geometric data types.
These add a "circle" data type, new operators and functions
for the existing data types, and change the default formats
for some of the existing types to make them consistant with
each other. Current formatting conventions (e.g. compatible
with v6.0 to allow dump/reload) are supported, but the new
conventions should be an improvement and we can eventually
drop the old conventions entirely.

For example, there are two kinds of paths (connected line segments),
open and closed, and the old format was

'(1,2,1,2,3,4)' for a closed path with two points (1,2) and (3,4)
'(0,2,1,2,3,4)' for an open path with two points (1,2) and (3,4)

Pretty arcane, huh? The new format for paths is

'((1,2),(3,4))' for a closed path with two points (1,2) and (3,4)
'[(1,2),(3,4)]' for an open path with two points (1,2) and (3,4)

For polygons, the old convention is

'(0,4,2,0,4,3)' for a triangle with points at (0,0),(4,4), and (2,3)

and the new convention is

'((0,0),(4,4),(2,3))' for a triangle with points at (0,0),(4,4), and (2,3)

Other data types which are also represented as lists of points
(e.g. boxes, line segments, and polygons) have similar representations
(they surround each point with parens).

For v6.1, any format which can be interpreted as the old style format
is decoded as such; we can remove that backwards compatibility but ugly
convention for v7.0. This will allow dump/reloads from v6.0.

These include some updates to the regression test files to change the test
for creating a data type from "circle" to "widget" to keep the test from
trashing the new builtin circle type.
1997-04-22 17:35:09 +00:00
Vadim B. Mikheev 051b4210e3 Fix for Hash and arrays 1997-04-22 03:32:38 +00:00
Marc G. Fournier 435b9ed2f2 Document --enable-cassert/--disable-cassert configure options 1997-04-21 18:26:27 +00:00
Vadim B. Mikheev 9f42a56a02 Fix for text_lt/text_le to avoid warnings if not def USE_LOCALE. 1997-04-21 04:31:53 +00:00
Vadim B. Mikheev 42e72503a1 #include <string.h> 1997-04-21 04:28:59 +00:00
Vadim B. Mikheev f3054b24c2 Fix for -Wno-error 1997-04-21 04:26:47 +00:00
Marc G. Fournier 85a95b9b0d Here is the Mismatched input/output patch for tintervals as reported over
the last week on Hackers...(A coulpe of clippings of the final
verdict are included below + the diff).

From: Wayde Nie <niew@phoenix.cis.mcmaster.ca>
1997-04-20 21:49:17 +00:00
Marc G. Fournier fd8e90a848 Add a --with-compiler switch that allows someone to specify:
--with-compiler=xlc

Requested by: Darren King <aixssd!darrenk@abs.net>
1997-04-18 18:43:28 +00:00
Marc G. Fournier 49153540da From: adrian@waltham.harvard.net
Subject: [HACKERS] Another patch to configure.in

I heard very little in objections/approvals to defaulting some of the
parameters to configure.  Enclosed is a patch to configure.in which
removes the questions for

        PGPORT
        USE_LOCALE
        NOHBA

By default (i.e. assuming you don't put anything extra in the configure
command line), it assumes PGPORT=5432, USE_LOCAL=no and NOHBA=no (i.e.
HBA is turned on)

        --with-pgport=PGPORT_NO         Over-rides the PGPORT value
        --enable-locale                 enables USE_LOCALE
        --disable-hba                   disables HBA

Just for completeness:

        --prefix=BASEDIR                Defaults to /usr/local/pgsql
        --with-template=TEMPLATE        Defaults to asking you
1997-04-18 18:34:11 +00:00
Vadim B. Mikheev 8466811335 Fix for -Wno-error 1997-04-18 08:57:39 +00:00
Vadim B. Mikheev d6b8f637f9 CommitInfoNeedsSave[buffer - 1] = 0
added to WriteBuffer(), FlushBuffer(), WriteNoReleaseBuffer().
1997-04-18 08:30:08 +00:00
Vadim B. Mikheev 538f58c04c #ifdef BTREE_BUILD_STATS enables to get executor stats for btree
building.
1997-04-18 03:37:57 +00:00
Vadim B. Mikheev d94c7fc4c5 1. Declaration
static const char *num_word(Cash value);
moved to cash.c.
2. 'extern ' added to funcs prototypes.
1997-04-18 02:59:26 +00:00
Vadim B. Mikheev 949ab57c7a Declaration
static const char *num_word(Cash value);
moved here from cash.h
1997-04-18 02:55:54 +00:00
Vadim B. Mikheev d3dfc664d0 PrintBufferUsage() changed to report about shared, local and direct
blocks transfferes.
1997-04-18 02:53:37 +00:00
Vadim B. Mikheev 55f5354380 Fix bttextcmp() to use unsigned char*.
#ifdef USE_LOCALE added.
1997-04-18 02:48:05 +00:00
Marc G. Fournier cbaa98835c From: Raymond Toy <toy@rtp.ericsson.se>
Subject: [PATCHES] 970417:  some large object patches


Two patches here, made against 970417.  Both have to do with large
objects:

        1.  lobjfuncs was not initialized in PQconnectdb.  This causes
            failure later if large objects are used.  (Someone already
            caught this error in PQsetdb.)

        2.  Postgres functions lo_import and lo_export sometimes
            produce garbage for the file names because the filename
            strings aren't always terminated by \0.  (VARDATA isn't
            necessarily null terminated.)
1997-04-17 20:39:31 +00:00
Marc G. Fournier 8834795ebf From: Raymond Toy <toy@rtp.ericsson.se>
Subject: [PATCHES] 970417:  two more patches for large objects

Here are two more patches:

        1.  pg_getint doesn't properly set the status flag when
            calling pqGetShort or pqGetLong.  This is required when
            accessing large objects via libpq.  This, combined with
            problem 1 above causes postgres to crash when postgres
            tries to print out the message that the status was not
            good.

        2.  ExceptionalCondition crashes when called with detail =
            NULL.  This patch prevents dereferencing the NULL.
1997-04-17 20:38:26 +00:00
Marc G. Fournier a1f229b19e From: "Martin J. Laubach" <mjl@CSlab.tuwien.ac.at>
Subject: [HACKERS] Patch: set date to euro/us postgres/iso/sql

  Here a patch that implements a SET date for use by the datetime
stuff. The syntax is

        SET date TO 'val[,val,...]'

  where val is us (us dates), euro (european dates), postgres,
iso or sql.

  Thomas is working on the integration in his datetime module.
I just needed to get the patch out before it went stale :)
1997-04-17 13:50:57 +00:00
Marc G. Fournier cfe0d67dc1 Some slight changes to the Wisconsin Benchmark tests since postgres requires
a -D<datadir> option
1997-04-17 13:48:52 +00:00
Vadim B. Mikheev a0d63ac98c The patch fixes a rare bug that may occur when one tries to vacuum a single
table. The table name is de-allocated by the CommitTransactionCommand()
in vc_init() before it is copied in VacRel.data and sometimes this causes
a SIGSEGV. My patch simply moves the strcpy before vc_init.

Submitted by Massimo Dal Zotto <dz@cs.unitn.it>.
1997-04-17 01:45:36 +00:00
Marc G. Fournier ba697c8c0b Fix a problem with Linux where yacc is *really* bison -y 1997-04-16 14:13:51 +00:00
Vadim B. Mikheev be0e8f7fb0 connectDB(): setsockopt (..., TCP_NODELAY, ...) added. 1997-04-16 06:29:19 +00:00
Vadim B. Mikheev 4d985ea96b StreamConnection(): setsockopt (..., TCP_NODELAY, ...) added. 1997-04-16 06:25:13 +00:00
Vadim B. Mikheev 329fb11262 1. BTREE_VERSION_1: using bti_itup->t_tid as unique identifier for a given
index tuple (logical position within A LEVEL). bti_oid & bti_dummy
taken off from BTItemData.
2. Fix for multi-column indices (nbtsearch.c):
   _bt_binsrch() - for searches on internal pages having keysize <
	number of attrs we point at the last item < the scankey, not at the
	first item = the scankey;
   _bt_moveright() - if keysize < number of attrs we compare scankey with
	_last_ item on current page to decide should we move right or
	not.
1997-04-16 01:48:29 +00:00
Vadim B. Mikheev afd9295786 BTREE_VERSION_1: using bti_itup->t_tid as unique identifier for a given
index tuple (logical position within A LEVEL). bti_oid & bti_dummy
taken off from BTItemData.
1997-04-16 01:21:59 +00:00
Marc G. Fournier cacaaed62b A couple of cleanups from Scott Harrison <Scott_Harrison@next.com> 1997-04-15 19:08:13 +00:00
Marc G. Fournier 94893bb962 Oops, don't forget to remove the CASSERT=true line 1997-04-15 18:36:45 +00:00
Marc G. Fournier f9d2ec0eba Have CASSERT enabled/disabled via configure, and passed through config.h
instead of as a -D
1997-04-15 18:35:50 +00:00
Marc G. Fournier 5dcc9bef6e Patch for Solaris 2.5 from: adrian@waltham.harvard.net 1997-04-15 18:18:45 +00:00
Marc G. Fournier 6fd4e2b414 Various minor HP related patches from:
Morten Kjeldgaard <mok@monster.kemi.aau.dk>
1997-04-15 17:55:37 +00:00
Marc G. Fournier 9778b946e5 A small fix, where default: condition in case had not 'break;'...not required,
but, IMHO, cleaner
1997-04-15 17:46:52 +00:00
Marc G. Fournier 88d740462f From: Thomas Lockhart <Thomas.G.Lockhart@jpl.nasa.gov>
Subject: [HACKERS] Money integration patches

Here are patches to integrate the money data type. I have included
some math and aggregate functions and have made the locale support optional
by #ifdef USE_LOCALE bracketing of functions.

Modules affected are:
builtins.h.patch
cash.c.patch
cash.h.patch
main.c.patch
pg_aggregate.h.patch
pg_operator.h.patch
pg_proc.h.patch
pg_type.h.patch

I changed the data type to be pass-by-reference rather than by-value
to pave the way for a larger internal representation (64-bit ints?).
Also, I changed the tabbing of cash.c and cash.h to match most of
the other Postgres source code files (4 space indent, 8 spaces == 1 tab).

The locale stuff should be tested under another convention (Russian?)
but I don't know what the correct results should be so perhaps someone
else can give them a try. Will update docs and regression tests in
the next few days.
1997-04-15 17:41:44 +00:00
Marc G. Fournier d8a300d867 2. The file /usr/local/pgsql/src/backend/lipq/pgcomprim.c has two
invalid macro definitions, the compiler complains about:

"pqcomprim.c", line 48.9: 1506-275 (S) Unexpected text ';' ignored.
"pqcomprim.c", line 61.9: 1506-275 (S) Unexpected text ';' ignored.

The ';' terminating the macro definition ntoh_s(n) on line 27 and
ntoh_l(n) on line 28 should be removed.


Pointed out by: Olaf Mittelstaedt <MSTAEDT@va-sigi.va.fh-ulm.de>
1997-04-15 17:25:47 +00:00
Marc G. Fournier 953ac7b55a Fix up the -Wno-error problem for non-gcc compilers
Pointed out by many many ppl
1997-04-15 17:24:26 +00:00
Marc G. Fournier a69c5fc81a Add ccsym to tools to determine OS/compiler specific symbols
Change BSD44_derived to __FreeBSD__ in numutils.c (need to know what
NetBSD is referred to as...someone?)
1997-04-13 17:09:45 +00:00
Marc G. Fournier f2b98c4624 Fixes for [] escaping pointed out by Adrian 1997-04-12 13:56:44 +00:00
Marc G. Fournier 32523e4cb8 scripts required by configure to bypass its inabilty to use []'s inside of
configure ([] have special means to m4 *sigh*)
1997-04-12 13:22:04 +00:00
Marc G. Fournier cecfd642f5 Make sure that Makefile.${PORTNAME} is link'd and that teh port/*.h
file that has moved to include is also link'd properly
1997-04-12 10:35:49 +00:00
Marc G. Fournier 09a5dabc30 Remove port specific Makefile 'targets' (ie. shared libraries) from
Makefile.global and move them to seperate 'include' makefiles

Over time, should become even more port specific:

	ie. Makefile.BSD44_derived should be broken down into netbsd/freebsd
specific ports
1997-04-12 10:33:10 +00:00
Marc G. Fournier 7113e880b8 More more of the include files under the include directory 1997-04-12 10:21:55 +00:00
Marc G. Fournier 9956fa056a remove the port related .h files from the top level directory.
Moved to include/port
1997-04-12 10:20:20 +00:00
Marc G. Fournier 02fa41951b Fix detection of install vs installbsd
Submitted by: adrian@waltham.harvard.net
1997-04-12 09:39:56 +00:00
Marc G. Fournier df2374f024 Make sure postgres.h is included before we start checking #ifdef's for other
header files.

Pointed out by: Edmund Mergl <E.Mergl@bawue.de>
1997-04-12 09:37:31 +00:00
Marc G. Fournier fcf7d45b36 Get rid of the .sql files out of the Makefile
Pointed out by: afc@teri.superlink.net
1997-04-12 09:34:31 +00:00
Marc G. Fournier 6da05a7b83 Major cleanup of Install instructions
Provided by: adrian@waltham.harvard.net
1997-04-12 09:33:25 +00:00
Marc G. Fournier 1e9b80a2fd modifications to pg_dump towards supporting dumping of ACLs (doesn't work yet!)
modification to c.h so that bool isn't typedef'd under __cplusplus
1997-04-12 09:24:23 +00:00
Marc G. Fournier bb0a17412d Change BACKEND to CFLAGS 1997-04-11 18:55:10 +00:00
Marc G. Fournier bc97905a15 Finish removing the TEST_MAIN stuff, which was mean for standalone
testing
1997-04-10 20:51:13 +00:00