Skip site navigation (1) Skip section navigation (2)

Re: session_id

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: abief_ag_-postgresql(at)yahoo(dot)com
Cc: Michael Fuhr <mike(at)fuhr(dot)org>, pgsql-sql(at)postgresql(dot)org
Subject: Re: session_id
Date: 2004-11-22 04:31:02
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-sql
Riccardo G. Facchini wrote:
> No, I can't provide it because your'e right. currval() is NOT affected
> by other sessions.
> Thanks anyway for the suggestion, using pg_backend_pid() solved the
> uniqueness I needed. I'll keep the nextval/currval for another
> opportunity.

FYI, we needed a unique-through-time session id for the log_line_prefix
so we used the seconds-since-1970-dot-pid.

  Bruce Momjian                        |
  pgman(at)candle(dot)pha(dot)pa(dot)us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073

In response to

pgsql-sql by date

Next:From: sreejith sDate: 2004-11-22 13:41:44
Subject: Doubt :- Image_Insert
Previous:From: Michael FuhrDate: 2004-11-22 01:09:18
Subject: Re: missing... at end of sql expression

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group