MySQL Stored Procedure Variable Example
Open your MySQL Query Editor then copy & paste the below code to make a Stored Procedure which will hold some variables in MySQL:
DELIMITER | CREATE PROCEDURE SP_VARIABLE_EXAMPLE () BEGIN DECLARE LastName VARCHAR(255) DEFAULT 'Noor.Hasan'; DECLARE WorkExperience INT DEFAULT 7; SELECT LastName, WorkExperience ; END; |
MySQL Stored Procedure Variable Example - MySQL Query Editor Output
Again open your MySQL Query Editor then copy & paste the below code to execute the Stored Procedure & get some interesting result:
call SP_VARIABLE_EXAMPLE;
MySQL Stored Procedure Example - Executing Stored Procedure - MySQL Query Editor Output
Related Tutorial Examples
- MySQL Stored Procedure: Batch Salary Increment Example
- MSSQL PRINT Like Function in MySQL Example
- How to Find MySQL Stored Procedure or Function Information
- How To Find MySQL SERVER VERSION Information
- MySQL Stored Procedure: INSERT INTO SELECT... Example
- MySQL sample database script: Create Database using SQL Statement Example
- MySQL Sub-Query: INSERT INTO SELECT... Example
- MySQL NULL value Example using PHP
- 20 steps to make CakePHP Blog Project
- PERL Example: Hellow world! program in PERL


No comments:
Post a Comment
leave your comments here..