Postgresql Update inside For Loop
问题 I'm new enough to postgresql, and I'm having issues updating a column of null values in a table using a for loop. The table i'm working on is huge so for brevity i'll give a smaller example which should get the point across. Take the following table +----+----------+----------+ | id | A | B | C | +----+----------+----------+ | a | 1 | 0 | NULL | | b | 1 | 1 | NULL | | c | 2 | 4 | NULL | | a | 3 | 2 | NULL | | c | 2 | 3 | NULL | | d | 4 | 2 | NULL | +----+----------+----------+ I want to write