Jump to content

can't execute StoredProcedure in mysql db


Rex

Recommended Posts

Hi djbob,

 

Thank for your hosting. It is a GREAT place!

 

My hosting account is babyname.

I logined into cpanel, opened the phpadmin and created a mysql db which name is "babyname_test" and some functions and stored procedures in the db. I also created a user as "babyname_user" and assigned all privileges of test db to this user.

 

In my PHP code, I can use "babyname_user" to connect and query db "babyname_test", but can't execute any stored procedures.

 

I don't know whether it is a bug of heliohost or cpanel.

 

Anyway I have passed this problem. Use PHP with the user to connect the db and create the sp and functions, then I can use these sp and functions in PHP code.

 

Link to comment
Share on other sites

You're probably the first person to try using MySQL stored procedures around here. They're relatively new and I'm not sure how supported they are from PHP or our version of MySQL, as well as if they work under cPanel's restrictions.

Link to comment
Share on other sites

haha, it is my honor. I am used to use stored precedures and hide others schema for db user. :)

another thing about sp, heliohost's phpMyAdmin will return error while trying to execute sp which returns some resultset.

It should be a bug of mysql API of php. mysqli should be ok.

 

You're probably the first person to try using MySQL stored procedures around here. They're relatively new and I'm not sure how supported they are from PHP or our version of MySQL, as well as if they work under cPanel's restrictions.

 

Link to comment
Share on other sites

  • 1 month later...
haha, it is my honor. I am used to use stored precedures and hide others schema for db user. :)

another thing about sp, heliohost's phpMyAdmin will return error while trying to execute sp which returns some resultset.

It should be a bug of mysql API of php. mysqli should be ok.

 

You're probably the first person to try using MySQL stored procedures around here. They're relatively new and I'm not sure how supported they are from PHP or our version of MySQL, as well as if they work under cPanel's restrictions.

 

well, it seems that i'm the second one to use stored procedures around here. =D

 

my phpmyadmin is not working, so i'm executing queries from my computer via toad for mysql.

 

i get the folowing error:

 

Connection 11/17/2009 9:53:42 PM Got 2 warning(s). 0 0

Connection 11/17/2009 9:53:42 PM 1410: You are not allowed to create a user with GRANT 0 0

Connection 11/17/2009 9:53:42 PM 1404: Failed to grant EXECUTE and ALTER ROUTINE privileges 0 0

Error 11/17/2009 9:53:43 PM 0:00:00.760 MySQL Database Error: execute command denied to user 'XXXXXXXXXXXXXXXX' for routine 'boreas_XXXXXXXX.myProc' 135 0

 

it seems that i can set a stored procedure, but cant call it. =/

 

it's still okay... i can make the same funcionality from php, but im used to SPs.

 

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...