DECLARE @caseId UNIQUEIDENTIFIER,
@fieldId UNIQUEIDENTIFIER,
@columnName NVARCHAR(MAX),
@dateValue DATETIME,
@tableName nvarchar(MAX);
set @command = 'update ' + @tableName + ' set ' + @columnName + ' = ' + @dateValue + ' where Id = ''' + @caseId + '''';
exec sp_executesql @command;
Getting error while running the update command. - The data types datetime and uniqueidentifier are incompatible in the add operator. Can someone help?