Re: Setting session global variables

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Jonathan Bartlett <johnnyb6(at)SDF(dot)lonestar(dot)org>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: Setting session global variables
Date: 2001-05-17 01:12:44
Message-ID: 8124.990061964@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Jonathan Bartlett <johnnyb6(at)SDF(dot)lonestar(dot)org> writes:
> However, the only way I can see to implement this is to have session
> global variables. Is there a way to fake session global variables with a
> table? Any comments would be appreciated.

You could do it with temp tables: the same temp table name would refer
to a different table in each session.

(You realize, of course, that CURRENT_USER already exists per SQL spec.
I assume you just meant that you'd like to have things *like*
CURRENT_USER, but defined by yourself...)

regards, tom lane

In response to

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Roberto Mello 2001-05-17 01:22:52 Re: Exp/Imp Problems...
Previous Message Jonathan Bartlett 2001-05-17 00:43:45 Setting session global variables