Re: Temp rows - is it possible?

From: Boris Popov <boris(at)procedium(dot)com>
To: Dennis Gearon <gearond(at)fireserve(dot)net>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Temp rows - is it possible?
Date: 2003-11-07 22:23:40
Message-ID: 84363973255.20031107142340@procedium.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hello Dennis,

Friday, November 7, 2003, 1:29:32 PM, you wrote:

DG> Boris Popov wrote:

>>Hello pgsql-general,
>>
>>I'm trying to implement a table with rows that are automatically
>>deleted when the session that inserted them disconnects, sort of like
>>our own alternative to pg_stat_activity. Is it possible and what
>>approach should I be trying to achieve such a thing?
>>

DG> who do you want it visible to? If you don't want it visible to
DG> anybody but the session you are writing them from, just don't
DG> commit them and use the right kind of transaction that allows you
DG> to see them from the session you are in.

I do want them to be visible to everybody. This is a sessions pool,
where sessions are inserted when our app connects and removed when it
disconnects, however this would only work for graceful disconnects,
which we all know isn't always the case. So I want a table that is
somehow notified of a session disconnect and deletes rows created by
that session.

Any ideas?

--
-Boris

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Edwin Quijada 2003-11-07 22:26:12 Re: Recovery Data Cant Be!!!
Previous Message Edwin Quijada 2003-11-07 22:09:34 Re: Recovery Data Cant Be!!!