The code for Create_GetTotalOrde_sessionr.sql is: DROP PROCEDURE IF EXISTS GetTotalOrder; DELIMITER $$ CREATE PROCEDURE GetTotalOrder() BEGIN #DECLARE totalOrder INT DEFAULT 0; # Session variables do not need to be declared. SELECT COUNT(*) INTO @totalOrder FROM orders; SELECT @totalOrder AS inside; END$$ DELIMITER ; CALL GetTotalOrder(); SELECT @totalOrder;