Skip to content

Instantly share code, notes, and snippets.

@prashant4224
Created May 31, 2020 15:41
Show Gist options
  • Save prashant4224/9fb623f231502a68b12b49dfef10ad71 to your computer and use it in GitHub Desktop.
Save prashant4224/9fb623f231502a68b12b49dfef10ad71 to your computer and use it in GitHub Desktop.
CREATE PROCEDURE `GetCityCountByName`(IN cityName varchar(255), OUT total INT)
BEGIN
select COUNT(*) into total from user where city=cityName;
END
//call test_db.GetCityCountByName('Belagavi', @total);
//select @total;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment