I would like to pass different parameters based on the day of the week (DOW) to a Stored Procedure. The T-SQL would be in a SQL Server Agent Job.Here is what I have but am getting syntax error(s):Declare @bkpType char(4)SELECT CASE(DATEPART(dw, CURRENT_TIMESTAMP))WHEN 1 THEN Set @bkpType = 'Full' -- SundayELSE Set @bkpType = 'Diff'ENDEXEC usp_BackupDB @bkpType
I want to take Differential backups M-Sat & Full backups on Sunday in one SQL Server Agent Job.Thanks