Re: Multi row sequence? - Mailing list pgsql-general

From Filip Wuytack
Subject Re: Multi row sequence?
Date
Msg-id 20041218171928.BA1553CC833@svr1.postgresql.org
Whole thread Raw
In response to Re: Multi row sequence?  (Bruno Wolff III <bruno@wolff.to>)
List pgsql-general
I'm working on a database that will contain companies (group) and the
relevant listing (securities-> id) and related periodic information. I want
the end users of the data to see the relationship between the 2 (comp A,
security 01, security 02;comp B, security 01, security 02) in the key
(company,security) as this would for part of the keys in all the other
related tables (depending if the info is on a company level or security
level and e.g using the date). By using a normal increment value as unique
key, I would loose this relation information in key, no?

Thanks for your input on this...

~ Filip

-----Original Message-----
From: Bruno Wolff III [mailto:bruno@wolff.to]
Sent: 18 December 2004 17:08
To: Filip Wuytack
Cc: pgsql-general@postgresql.org
Subject: Re: Multi row sequence?

On Fri, Dec 17, 2004 at 11:10:12 -0000,
  Filip Wuytack <fwuytack@fgscapital.com> wrote:
> Hi,
>
> I just started looking into PostgreSQL (coming from Mysql before), but
have
> a question:
>
> Is it possible to have a sequence (as a multirow prim key), where sequence
> (id) only increase per group of data (grp).

Why do you want to do this? It would be a lot simpler to generate unique
values over the table and that will work just fine if all you need
is uniqueness.



pgsql-general by date:

Previous
From: Bruno Wolff III
Date:
Subject: Re: transactions in multiple action rules
Next
From: "Sim Zacks"
Date:
Subject: Israel Go-Linux conference