Hi i am getting exception in my mssql code. Here is the exception:
Incorrect syntax near the keyword 'set' and 'as'.
And here is the my sql code:
UPDATE SET TBLSurvey.Status=-1 FROM TBLSurvey
RIGHT JOIN (
SELECT OrderId
FROM [CRM_NEW].[dbo].[TBLSurvey]
GROUP BY OrderId HAVING(COUNT(*)>1)) AS sd ON TBLSurvey.OrderID=sd.OrderId
WHERE AnswerDate IS NULL AND Status=0
Have no idea.