Bruno Wolff III <bruno(at)wolff(dot)to> writes:
> Rod Taylor <pg(at)rbt(dot)ca> wrote:
>> It is likely that you are missing an index on one of those foreign key'd
> I don't think that is too likely as a foreign key reference must be a
> unique key which would have an index. I think the type mismatch
> suggestion is probably what the problem is.
I agree. It is possible to have a lack-of-index problem on the
referencing column (as opposed to the referenced column), but that
normally only hurts you for deletes from the referenced table.
> The current solution is to make the types match. In 8.0.0 it would probably
> work efficiently as is, though it isn't normal for foreign keys to have a type
> mismatch and he may want to change that anyway.
8.0 will not fix this particular issue, as I did not add any numeric-vs-int
comparison operators. If we see a lot of complaints we could think
about adding such, but for 8.0 only the more common cases such as
int-vs-bigint are covered.
regards, tom lane
In response to
- Re: insert at 2004-08-13 15:02:43 from Bruno Wolff III
pgsql-performance by date
|Next:||From: Richard Huxton||Date: 2004-08-13 19:23:52|
|Subject: Re: Weird Database Performance problem!|
|Previous:||From: Josh Berkus||Date: 2004-08-13 18:01:52|
|Subject: Re: Reiser4|