Commit Graph

18003 Commits

Author SHA1 Message Date
Peter Eisentraut
a837ed88b1 Detect locale/encoding mismatch in initdb, or pick a suitable encoding
automatically if none was specified.
2004-07-14 17:55:10 +00:00
Bruce Momjian
bbcee544aa Have \dn+ show permissions and description for schemas.
Dennis Bjorklund
2004-07-13 16:48:16 +00:00
Bruce Momjian
dc0e76ca36 Change pg_dump to use ALTER OWNER commands instead of SET SESSION
AUTHORIZATION commands by default.  Move all GRANT and REVOKE commands
to the end of the dump to avoid restore failures in several situations.
Bring back --use-set-session-authorization option to get previous SET
behaviour

Christopher Kings-Lyne
2004-07-13 03:00:17 +00:00
Tom Lane
e419c84c56 Can't have blank lines in resultmap; some versions of expr complain. 2004-07-13 02:55:25 +00:00
Bruce Momjian
6577f178e6 Add new join file. 2004-07-13 02:54:08 +00:00
Bruce Momjian
ca95bcb1d8 Move tablespace name up on to the same line in psql \d. 2004-07-13 02:46:21 +00:00
Bruce Momjian
74f7630093 Rename join ordering named join_1.out 2004-07-13 02:05:09 +00:00
Tom Lane
9df3086972 Cause libpq and ecpg libraries to be built as proper shared libraries
(.dylib format) on Mac OS X, while not messing up loadable modules for
the backend (which are the same kind of animal as a shared library on
every other platform, but not here).  Also get the naming convention
to match OS X practice, viz libFOO.version.so not libFOO.so.version.
In support of that last, refactor code in Makefile.shlib to make it
easier to have platform-specific shlib naming conventions.
This patch is loosely based on the Fink project's current postgresql.patch.
Tested by yours truly on OS X 10.3.4; does anyone have 10.2.* to check
it on?
2004-07-13 00:06:46 +00:00
Peter Eisentraut
8b6f76af46 Make installation instructions match reality. 2004-07-12 22:12:34 +00:00
Bruce Momjian
b6335b4fb4 Add tablespace location display for psql \d.
Gavin Sherry
2004-07-12 20:41:13 +00:00
Bruce Momjian
e47cbb3bad Add has_tablespace_privilege().
Christopher Kings-Lynne
2004-07-12 20:23:59 +00:00
Bruce Momjian
1a0f3e476b Add Win32-specific join ordering. 2004-07-12 20:11:37 +00:00
Bruce Momjian
15c8fd70e8 Add blank line to new canonicalize_path file, which handles "a b\" properly. 2004-07-12 19:27:31 +00:00
Bruce Momjian
5ee0a8dcb6 canonicalization adjustments. 2004-07-12 19:18:18 +00:00
Bruce Momjian
a4c71af2c0 Put back canonicalization of PGDATA environment variable. 2004-07-12 19:15:14 +00:00
Bruce Momjian
76e7e2e776 Use strdup in pg_ctl for canonicalize_path on environment variable.
Simplify postmaster call too.
2004-07-12 18:17:13 +00:00
Bruce Momjian
a0db74a35c This patch adds the following options to pg_dumpall, to be passed to
pg_dump:

-S, --superuser=NAME

-O, --no-owner

-X disable-dollar-quoting, --disable-dollar-quoting

-X disable-triggers, --disable-triggers

Christopher Kings-Lynne
2004-07-12 14:35:45 +00:00
Bruce Momjian
96b9dc1aef The attached patch, which incorporates the previous one sent and
currently unapplied regarding spi_internal.c, makes some additional
fixes relating to return types, and also contains the fix for
preventing  the use of insecure versions of Safe.pm.

There is one remaing return case that does not appear to work, namely
return of a composite directly in a select, i.e. if  foo returns some
composite type, 'select * from foo()' works but 'select foo()' doesn't.
We will either fix that or document it as a limitation.

The function plperl_func_handler is a mess - I will try to get it
cleaned up (and split up) in a subsequent patch, time permitting.

Also, reiterating previous advice - this changes slightly the API for
spi_exec_query - the returned object has either 2 or 3 members: 'status'
(string) and 'proceesed' (int,- number of rows) and, if rows are
returned, 'rows' (array of tuple hashes).

Andrew Dunstan
2004-07-12 14:31:04 +00:00
Bruce Momjian
f4c5e06edf > win32 doesn't support a static initializer for mutexes, thus the first
> user must initialize the lock. The problem are concurrent "first" users
> - the pthread_mutex_t initialization must be synchronized.
> The current implementation is broken, the attached patches fixes that:
> mutex_initlock is a spinlock. If the pthread_mutex_t mutex is not
> initialized, then the spinlock is acquired, if the pthread_mutex_t is
> initialized if it's not yet initialized and then the spinlock is dropped.

Manfred Spraul
2004-07-12 14:23:28 +00:00
Bruce Momjian
a29d26a3cd Back out thread fix until I get clarification. 2004-07-12 14:16:28 +00:00
Bruce Momjian
a41463e31c win32 doesn't support a static initializer for mutexes, thus the first
user must initialize the lock. The problem are concurrent "first" users
- the pthread_mutex_t initialization must be synchronized.
The current implementation is broken, the attached patches fixes that:
mutex_initlock is a spinlock. If the pthread_mutex_t mutex is not
initialized, then the spinlock is acquired, if the pthread_mutex_t is
initialized if it's not yet initialized and then the spinlock is
dropped.

Manfred Spraul
2004-07-12 14:11:17 +00:00
Tom Lane
c14a43f657 Remove TABLESPACE option of CREATE SEQUENCE; sequences will now always
live in database or schema's default tablespace, as per today's discussion.
Also, remove some unused keywords from the grammar (PATH, PENDANT,
VERSION), and fix ALSO, which was added as a keyword but not added
to the keyword classification lists, thus making it worse-than-reserved.
2004-07-12 05:38:11 +00:00
Bruce Momjian
c5ff895c48 New text. 2004-07-12 03:58:34 +00:00
Bruce Momjian
298e58cbc4 Fix library_path with canonicalization. 2004-07-12 02:22:51 +00:00
Bruce Momjian
66d56a8efe Fix username mismatch in initdb. Magnus. 2004-07-12 01:54:10 +00:00
Bruce Momjian
a919fdfd3d Wording improvement. 2004-07-12 01:37:01 +00:00
Bruce Momjian
7bcdf2ebee Tablespace examples for CREATE TABLE/INDEX/SCHEMA/DATABASE as well as
some other examples for CREATE DATABASE.

Gavin Sherry
2004-07-12 01:22:53 +00:00
Bruce Momjian
3095c104f0 Move comma. 2004-07-12 01:10:17 +00:00
Bruce Momjian
eba9be883c The outer #define was forgotten. Attached patch adds it; please apply.
Alvaro
2004-07-12 01:00:45 +00:00
Bruce Momjian
098d0304d7 Add:
> * Add session start time and last statement time to pg_stat_activity
2004-07-12 00:39:11 +00:00
Bruce Momjian
1ec448cda3 Added Matthew:
<   rather than in /contrib
>   rather than in /contrib (Matthew)
515a516
> * Matthew T. O'Connor <matthew@zeut.net>
2004-07-12 00:23:59 +00:00
Bruce Momjian
233afe6a90 New Czech FAQ.
Pavel Stehule
2004-07-12 00:22:51 +00:00
Bruce Momjian
2bd17a5f52 Add FAQ entry on hardware selection. 2004-07-12 00:18:57 +00:00
Bruce Momjian
118ec0daa8 Canonicalize preload_libraries after it is split up, not before. 2004-07-12 00:09:07 +00:00
Bruce Momjian
0589ab68c5 Remove:
< * Allow moving sequences and toast tables to other tablespaces
2004-07-11 23:52:05 +00:00
Bruce Momjian
421089dc35 Cleanup for canonicalization fixes, from Tom. 2004-07-11 23:49:51 +00:00
Bruce Momjian
a1f3209c07 Add:
> * Allow moving sequences and toast tables to other tablespaces
2004-07-11 23:31:27 +00:00
Bruce Momjian
8dbd10d96d This patch fixes a small error in the Porting PL/SQL to PL/pgSQL
section where a instr function parameter is mistyped as varchar. It
works properly when changed to integer.

Michael Glaesemann
2004-07-11 23:26:51 +00:00
Bruce Momjian
cf9fd800ec Example for create function using argument names
Gavin Sherry
2004-07-11 23:23:43 +00:00
Tom Lane
af4de81469 ALTER TABLE SET TABLESPACE. Gavin Sherry, some rework by Tom Lane. 2004-07-11 23:13:58 +00:00
Bruce Momjian
08d89db34d Update German FAQ> 2004-07-11 23:07:18 +00:00
Bruce Momjian
d7c89ea9b2 Update URL's for mysql conversion tools. 2004-07-11 22:52:18 +00:00
Bruce Momjian
5c9d069daf Add:
> * Add NOVICE output level for helpful messages like automatic sequence/index creation
2004-07-11 21:57:03 +00:00
Bruce Momjian
5ff9566686 Remove postgresql.conf of 'info' as a valid client_min_messages level. 2004-07-11 21:48:25 +00:00
Bruce Momjian
7b0f060d54 Use canonicalize_path for -D, GUC paths, and paths coming in from
environment variables.
2004-07-11 21:34:04 +00:00
Tom Lane
8801110b20 Move TablespaceCreateDbspace() call into smgrcreate(), which is where it
probably should have been to begin with; this is to cover cases like
needing to recreate the per-db directory during WAL replay.
Also, fix heap_create to force pg_class.reltablespace to be zero instead
of the database's default tablespace; this makes the world safe for
CREATE DATABASE to handle all tables in the default tablespace alike,
as per previous discussion.  And force pg_class.reltablespace to zero
when creating a relation without physical storage (eg, a view); this
avoids possibly having dangling references in this column after a
subsequent DROP TABLESPACE.
2004-07-11 19:52:52 +00:00
Tom Lane
94d4d240bb Rename XLOG_BTREE_NEWPAGE xlog record type into XLOG_HEAP_NEWPAGE, and
shift support code into heapam.c accordingly.  This is in service of
soon-to-be-committed ALTER TABLE SET TABLESPACE code that will want to
use this same record type for both heaps and indexes.

Theoretically I should have forced initdb for this, but in practice there
is no change in xlog contents because CVS tip will never really emit this
record type anyhow...
2004-07-11 18:01:45 +00:00
Bruce Momjian
98e9775a3a Use standard macro for psql binary file open. Add comment explaining
control-z requirement.
2004-07-11 13:29:16 +00:00
Tom Lane
c8c40bbc9e Cause the format of BC timestamptz output to be 'datetime zone BC' rather
than 'datetime BC zone', because the former is accepted by the timestamptz
input converter while the latter may not be depending on spacing.  This
is not a loss of compatibility w.r.t. 7.4 and before, because until very
recently there was never a case where we'd output both zone and 'BC'.
2004-07-11 04:57:20 +00:00
Bruce Momjian
59429adea9 Add:
> * Allow moving system tables to other tablespaces, where possible
2004-07-11 03:10:50 +00:00