Postgresql - UPDATE with different WHERE clasules
It would be helpful if you gave tables and columns, but something like this might work. Basically, move the WHERE into a case statement and set the column equal to itself if the condition is not met.

WITH sub_select(SELECT column1, column2, column3 FROM my_large_table)
UPDATE my_second_table
SET first_col = case when column3 &gt; 1 then column1 else first_col end
, second_col = case when column 3 = 1 then column2 else second_col end
FROM sub_selection;