Multiple Sequence Number for One Column p.2 - Mailing list pgsql-general

From alexander
Subject Multiple Sequence Number for One Column p.2
Date
Msg-id 56B092DD.7070203@gmail.com
Whole thread Raw
Responses Re: Multiple Sequence Number for One Column p.2
List pgsql-general
Hello

I've met exactly the same problem as described here
http://www.postgresql.org/message-id/95862fdc-eb2e-4533-8331-d49775b0ef8f@f2g2000yqf.googlegroups.com
. For now, I use the same solution that was presented in the response
http://www.postgresql.org/message-id/077DA5F9-F783-4388-BF19-42E582DC89EE@yahoo.com
.

In my case, I have a composite key composed of session ID and object ID.
Session ID is a unique value. I'd like to have a separate auto
incremental key for each session ID value. Therefore, I create a
sequence for each session ID. The problem is that once the session has
ended there won't be new values with its session ID, so, we have to
clear obsolete sequences related to this ID from time to time.

It's said in the last message that there are other solutions. It would
be helpful for me to know the others if they exist in terms of PostgreSQL.

Thanks in advance,
Alexander Aleksiyants.


pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: Attachments
Next
From: "Weisenberg, Sofy Hefets"
Date:
Subject: Postgres 9.5 - password for new windows user