diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2002-05-17 01:19:19 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2002-05-17 01:19:19 +0000 |
commit | f0811a74b37427d7ee5eee56b00f7f2ea323d7d6 (patch) | |
tree | 51a596c44fd21144383062aa7d2ce852ae270268 /src/backend/utils/adt/datetime.c | |
parent | fa613fa1eafd8fd80272a31e8477ad9368c95dbb (diff) | |
download | postgresql-f0811a74b37427d7ee5eee56b00f7f2ea323d7d6.tar.gz postgresql-f0811a74b37427d7ee5eee56b00f7f2ea323d7d6.zip |
Merge the last few variable.c configuration variables into the generic
GUC support. It's now possible to set datestyle, timezone, and
client_encoding from postgresql.conf and per-database or per-user
settings. Also, implement rollback of SET commands that occur in a
transaction that later fails. Create a SET LOCAL var = value syntax
that sets the variable only for the duration of the current transaction.
All per previous discussions in pghackers.
Diffstat (limited to 'src/backend/utils/adt/datetime.c')
-rw-r--r-- | src/backend/utils/adt/datetime.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/src/backend/utils/adt/datetime.c b/src/backend/utils/adt/datetime.c index 1a908d9d6b7..d6e0358e817 100644 --- a/src/backend/utils/adt/datetime.c +++ b/src/backend/utils/adt/datetime.c @@ -8,7 +8,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/utils/adt/datetime.c,v 1.89 2002/04/21 19:48:12 thomas Exp $ + * $Header: /cvsroot/pgsql/src/backend/utils/adt/datetime.c,v 1.90 2002/05/17 01:19:18 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -3571,11 +3571,17 @@ EncodeInterval(struct tm * tm, fsec_t fsec, int style, char *str) } /* EncodeInterval() */ -void -ClearDateCache(bool dummy) +/* GUC assign_hook for australian_timezones */ +bool +ClearDateCache(bool newval, bool doit, bool interactive) { int i; - for (i = 0; i < MAXDATEFIELDS; i++) - datecache[i] = NULL; + if (doit) + { + for (i = 0; i < MAXDATEFIELDS; i++) + datecache[i] = NULL; + } + + return true; } |