How can I assign a multiple-field-function result on PostgreSQL updates -
i'm looking optimized method in postgresql that:
update table1 set (a,b)=(somecomplexfunction(table1.something),2*somecomplexfunction(table1.something)) ...
this calculates somecomplexfunction(table1.something) twice, i'd that:
update table1 set (a,b)=somecomplexvectorfunction(table1.something) ...
but update syntax not support multiple field functions. ideas?
update table1 set = somecomplexfunction(table1.something), b = * 2 ...
Comments
Post a Comment