I want to update a Column in a Table, based on the minimum of another column of the same table.
eg.
JobPositonId | JobPositonName | JobDescriptionId | ContactId
1 | 1 | 1 | 1
2 | 1 | 1 | 0
3 | 1 | 1 | 0
I want to update ContactId to be 1, if it is 0 and where JobPositionId is the lowest.