Re: infinite loop in an update statement - Mailing list pgsql-general

From Adrian Klaver
Subject Re: infinite loop in an update statement
Date
Msg-id 4f5c2262-f869-4707-93cb-735267903da4@aklaver.com
Whole thread Raw
In response to infinite loop in an update statement  (Fabrice Chapuis <fabrice636861@gmail.com>)
List pgsql-general
On 9/9/24 07:55, Fabrice Chapuis wrote:
> Hi,
> 
> table a and b are empty, this query does not return. It seems we enter 
> in infinite loop.
> why this update does not return instantly?
> 
> UPDATE table_a a
>   SET col1 = (SELECT MIN(b.col1)
>                      FROM table_b b
>                      WHERE b.col2 = a.col2)

Do you have an UPDATE trigger on table_a?

> 
> Regards,
> 
> Fabrice
> 
> 

-- 
Adrian Klaver
adrian.klaver@aklaver.com




pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: infinite loop in an update statement
Next
From: Adrian Klaver
Date:
Subject: Re: Connection between PostgreSQL and SAP HANA database