Aim: Update Column C 'New Date' based on finding a value in Column B 'valuefield'. Column C 'New Date' will be a date from Column A 'Current Date'
I have used the below in the past but I am now asked for a third argument. I have search and tried "YYYY-MM-DD" at the end but can't quite make the leap to the answer.
Software:I am using SQL in Server Management(2012)
UPDATE TBLTABLE
SET NewDate= (CurrentDate + DATEADD(DAY,730))
WHERE VALUEFIELD = 'XYZ'
Notes: Updating with a known value I know but I don't 'know' the value of each 'Current Date' field and this also ensures I don't have to run distinct date.
Looked at: Update Field based on another table's Field values