I have the following the code from a book but I'm getting the following error. Not Sure why. I run this into SQL Server Management Studio and create a new store procedure... What I'm missing>
DROP PROCEDURE IF EXISTS customer_sales
CREATE PROCEDURE customer_sales
READS SQL DATA
DECLARE total_sales NUMERIC(8,2);
SELECT CONCAT('Total sales for ',in_customer_id,' is ',total_sales);
Msg 156, Level 15, State 1, Line 1
Incorrect syntax near the keyword 'IF'.
Msg 102, Level 15, State 1, Line 4
Incorrect syntax near 'in_customer_id'.
Msg 155, Level 15, State 2, Line 7
'NUMERIC' is not a recognized CURSOR option.
Msg 195, Level 15, State 10, Line 14
'CONCAT' is not a recognized built-in function name.