UPDATE table SET c.expirydate= DATEADD(yy, 5,r.enddate), FROM co_batch_master c INNER JOIN co_batch_master r ON c.id = r.id</pre>
Select *, DATEADD(yy, 5, ENDDATE) as ExpiryDate from co_batch_master
DATEADD(YY,5,enddate)
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)