Merlin Moncure writes:
> On Thu, Nov 12, 2015 at 9:48 AM, Craig James wrote:
>> What about a warning on creation?
>>
>> db=> create table foo(i integer primary key);
>> db=> create table bar(j integer primary key, i integer);
>> db=> alter table bar add constraint fk_bar foreign key(i) reference
On Thu, Nov 12, 2015 at 9:48 AM, Craig James wrote:
>
> On Thu, Nov 12, 2015 at 7:12 AM, Merlin Moncure wrote:
>>
>> On Wed, Nov 11, 2015 at 1:33 PM, Tom Lane wrote:
>> > Massalin Yerzhan writes:
>> >> I'm having an issue. The query never ends:
>> >> delete from bb_gamelist_league;
>> >
>> > 9
On Thu, Nov 12, 2015 at 7:12 AM, Merlin Moncure wrote:
> On Wed, Nov 11, 2015 at 1:33 PM, Tom Lane wrote:
> > Massalin Yerzhan writes:
> >> I'm having an issue. The query never ends:
> >> delete from bb_gamelist_league;
> >
> > 9 times out of 10, the answer to this type of problem is that you h
Merlin Moncure writes:
> On Wed, Nov 11, 2015 at 1:33 PM, Tom Lane wrote:
>> If you're not sure which table is the problem, try doing an EXPLAIN
>> ANALYZE of a DELETE that will only remove a few rows. You should
>> see some time blamed on a trigger associated with the FK constraint.
> You've a
On Wed, Nov 11, 2015 at 1:33 PM, Tom Lane wrote:
> Massalin Yerzhan writes:
>> I'm having an issue. The query never ends:
>> delete from bb_gamelist_league;
>
> 9 times out of 10, the answer to this type of problem is that you have
> some table referencing this one by a foreign key, and the refer