From: | Andreas Kretschmer <akretschmer(at)spamfence(dot)net> |
---|---|
To: | pgsql-general(at)postgresql(dot)org |
Subject: | Re: partitioned lookup table? |
Date: | 2010-04-17 09:39:28 |
Message-ID: | 20100417093928.GA30573@tux |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Vick Khera <vivek(at)khera(dot)org> wrote:
> On Fri, Apr 16, 2010 at 10:48 AM, Andreas Kretschmer
> <akretschmer(at)spamfence(dot)net> wrote:
> > is it possible to partitionate a lookup-table? What i mean is:
> >
> > test=# create table foo(i int primary key);
> > NOTICE: CREATE TABLE / PRIMARY KEY will create implicit index "foo_pkey" for table "foo"
> > CREATE TABLE
> > test=*# create table bla ( i int references foo);
>
> You can have FK references from a partitioned table, but not to the
> table. That is, you cannot have this FK reference since you are
> partitioning foo. You can mimic the FK tests by writing your own
> triggers that have knowledge of how you split the table, but they will
> not be as efficient as a built-in FK test.
Thx for the answer, and yes, this is what i had in mind.
Andreas
--
Really, I'm not out to destroy Microsoft. That will just be a completely
unintentional side effect. (Linus Torvalds)
"If I was god, I would recompile penguin with --enable-fly." (unknown)
Kaufbach, Saxony, Germany, Europe. N 51.05082°, E 13.56889°
From | Date | Subject | |
---|---|---|---|
Next Message | Martin Gainty | 2010-04-17 13:16:55 | Re: partitioned lookup table? |
Previous Message | John R Pierce | 2010-04-17 08:02:52 | Re: Int64GetDatum |