X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id 6512D9DCBBD for ; Thu, 2 Mar 2006 11:33:16 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 91456-04 for ; Thu, 2 Mar 2006 11:33:20 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from ll.mit.edu (LLMAIL.LL.MIT.EDU [129.55.12.40]) by postgresql.org (Postfix) with ESMTP id 3788F9DCAAF for ; Thu, 2 Mar 2006 11:33:13 -0400 (AST) Received: (from smtp@localhost) by ll.mit.edu (8.12.10/8.8.8) id k22FXH8V006927 for ; Thu, 2 Mar 2006 10:33:17 -0500 (EST) Received: from UNKNOWN( ), claiming to be "sty.llan" via SMTP by llmail, id smtpdAAADCa4hn; Thu Mar 2 10:33:11 2006 Date: Thu, 2 Mar 2006 10:33:10 -0500 From: george young To: pgsql-sql@postgresql.org Subject: Re: Change date format through an environmental variable? Message-Id: <20060302103310.5ea5ccad.gry@ll.mit.edu> In-Reply-To: <4405DAAA.4010908@noaa.gov> References: <4405DAAA.4010908@noaa.gov> Reply-To: gry@ll.mit.edu Organization: MIT Lincoln Laboratory X-Mailer: Sylpheed version 2.0.1 (GTK+ 2.8.0; i686-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.094 required=5 tests=[AWL=0.093, UNPARSEABLE_RELAY=0.001] X-Spam-Score: 0.094 X-Spam-Level: X-Archive-Number: 200603/47 X-Sequence-Number: 24393 Try the PGDATESTYLE environment variable. Works in 7.4 and 8.1, though it is claimed to be deprecated. -- George Young On Wed, 01 Mar 2006 12:32:26 -0500 Mark Fenbers threw this fish to the penguins: > I want to get Pg (v7.4.7) to output a date field in a different format > than yyyy-mm-dd through the use of an environmental variable (because I > have no access the SQL). Is this possible? I know about the DATESTYLE > variable, but that seems to work only within a query transaction, and > has no effect if trying to set it as an envvar. > > Mark > > ---------------------------(end of broadcast)--------------------------- > TIP 5: don't forget to increase your free space map settings > -- "Are the gods not just?" "Oh no, child. What would become of us if they were?" (CSL)