What is wrong with below update query? it gives syntax error the error message is as below:
Msg 102, Level 15, State 1, Line 1
Incorrect syntax near 'a'.
Code:
UPDATE D_date a
SET d_date_key = b.d_date_key,
full_date = b.full_date,
day_of_week = b.day_of_week,
day_of_week_display = b.day_of_week_display,
fiscal_day_number = b.fiscal_day_number
FROM
dbo.[2017 Calendar update] b
WHERE
a.d_date_key = b.d_date_key;