pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Peter <peter@greatnowhere.com>
To: pgsql-jdbc@postgresql.org
Subject: Re: Totally weird behaviour in org.postgresql.Driver
Date: Wed, 18 Mar 2009 12:13:06 +0200
Message-ID: <49c0c935$0$1343$834e42db@reader.greatnowhere.com> (raw)
References: <49b7bfef$0$1343$834e42db@reader.greatnowhere.com>
	<491f66a50903120342j67e87c7dob10cfdc23580c8f4@mail.gmail.com>
	<003001c9a315$a68a9330$f39fb990$@com>
	<200903121341.59498.cservin@cromagnon.com>
	<49bca9e8$0$1341$834e42db@reader.greatnowhere.com>
	<491f66a50903150409y648b448pc3825ef4fc1ed7e@mail.gmail.com>
	<49bcfe15$0$1344$834e42db@reader.greatnowhere.com>
	<49BDABC7.3030108@burntmail.com>
	<491f66a50903160257m3cd01c07v828a33fab173e775@mail.gmail.com>
	<49bf5e7f$0$1347$834e42db@reader.greatnowhere.com>
	<49BFD848.5040207@burntmail.com>

> Yes, that is what I was suggesting in my previous post.  From an old 
> thread titled "can I define own variables?":
>
> =======
> To do this, you need to set custom_variable_classes in postgresql.conf,
> perhaps
>     custom_variable_classes = uservars
>
> and then you can do things like
>
>     SET uservars.foo = whatever;
>     SHOW uservars.bar;
> ======
>
> So, you can use pooled connections for scalability.  After you retrieve a 
> connection, set your user variable to contain the end user identifier. 
> Then you can retrieve it as necessary (e.g., in a trigger) for the 
> duration of the connection.


Excellent suggestion! Thanks a lot!

Peter 





view thread (22+ messages)

Message-ID: <49c0c935$0$1343$834e42db@reader.greatnowhere.com>
Permalink:  ../49c0c935$0$1343$834e42db@reader.greatnowhere.com/
Also on:    postgresql.org/message-id/49c0c935$0$1343$834e42db@reader.greatnowhere.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-jdbc@postgresql.org
  Cc: peter@greatnowhere.com
  Subject: Re: Totally weird behaviour in org.postgresql.Driver
  In-Reply-To: <49c0c935$0$1343$834e42db@reader.greatnowhere.com>
  References: <49b7bfef$0$1343$834e42db@reader.greatnowhere.com> <491f66a50903120342j67e87c7dob10cfdc23580c8f4@mail.gmail.com> <003001c9a315$a68a9330$f39fb990$@com> <200903121341.59498.cservin@cromagnon.com> <49bca9e8$0$1341$834e42db@reader.greatnowhere.com> <491f66a50903150409y648b448pc3825ef4fc1ed7e@mail.gmail.com> <49bcfe15$0$1344$834e42db@reader.greatnowhere.com> <49BDABC7.3030108@burntmail.com> <491f66a50903160257m3cd01c07v828a33fab173e775@mail.gmail.com> <49bf5e7f$0$1347$834e42db@reader.greatnowhere.com> <49BFD848.5040207@burntmail.com> <49c0c935$0$1343$834e42db@reader.greatnowhere.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox