fogofogo Posted June 15, 2010 Share Posted June 15, 2010 Hello, I'm trying to create a stored procedure through phpmyadmin and its giving me an error. Heres my query... DROP PROCEDURE IF EXISTS `LoginUser` GO CREATE PROCEDURE LoginUser( IN p_Alias varchar(30) ) BEGIN SELECT FirstName FROM users WHERE Alias = p_Alias; END GO Its giving me an error saying ... check the manual that corresponds to your MySQL server version for the right syntax to use near 'GO Can anyone see the obvious error I'm making? Sorry I'm new to this. Cheers Quote Link to comment https://forums.phpfreaks.com/topic/204836-problem-creating-a-stored-procedure-in-mysql-5/ Share on other sites More sharing options...
fogofogo Posted June 15, 2010 Author Share Posted June 15, 2010 looks like I messed it up. This fixed it CREATE PROCEDURE LoginUsers(IN palias VARCHAR(30), OUT pFirstName VARCHAR(30)) BEGIN SELECT FirstName INTO pFirstName FROM users WHERE Alias=palias; END Quote Link to comment https://forums.phpfreaks.com/topic/204836-problem-creating-a-stored-procedure-in-mysql-5/#findComment-1072360 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.