As a simplifying example, I have
tbl:flip `sym`v1`v2!(`a`b`c`d; 50 280 1200 1800; 40 190 1300 1900)
and I d like to pass a column name into a function like
f:{[t;c];:update v3:2 * c from t;}
In this form it doesnt work. any suggestion how I can make this happen? Thanks
":". Adding a semi-colon to the end of your update statement suppresses the output which is why you would need to set the return of the function but by removing that semi-colon the function will return the output automatically. So your function can look likef:{[t;c] update v3:2 * c from t}You can also see another example of this in Thomas' answer.