Access denied when using stored procs

Questions about the MySQL, PostgreSQL, and most other databases, as well as using it with PHP can be asked here.

Moderator: General Moderators

Post Reply
GeXus
Forum Regular
Posts: 631
Joined: Sat Mar 11, 2006 8:59 am

Access denied when using stored procs

Post by GeXus »

There are actually to issues... one is syntax one is access... When I do the following

Code: Select all

CREATE PROCEDURE sp_get_category()
BEGIN
SELECT category_id FROM categories;
END;
I receive a syntax error for the 'select...' (note, im using query browser to excute this)..

Now when I do this..
CREATE PROCEDURE sp_get_category()
BEGIN

END;
I receive access is denied. If I do the select outside of a procedure, then it executes fine, and i'm connected to that DB, so not sure why I would get that.

any ideas?

Thanks!
Post Reply