Forums

Error uploading stored procedures

Update: I actually found the problem, the DEFINER definition is actually optional, I removed it and everything works fine now! Thanks.

I'm working on a student project and I got the following errors when I tried to upload my stored procedures:

ERROR 1227 (42000): Access denied; you need (at least one of) the SUPER privilege(s) for this operation

My stored procedures is like this:

DELIMITER $$ CREATE DEFINER="myusername"@"mydatabase_host_address" PROCEDURE pname(
IN invar VARCHAR(100)
)

BEGIN
SELECT * FROM database_name.table_name WHERE colname=invar;

END$$

DELIMITER ;

I was wondering if I did something wrong in the code above?

glad you figured it out! :)