I recently had this issue where I created a database user and gave delete and update permission. Yet, I was getting permission denied on a delete query.

Create user: create user username password 'whatever';

Grant: grant update, delete on table to username;

Query which gave permission denied:

delete from table
where condition1 and
condition2 and

After a bit of hunting I realized that maybe I am getting this error because I am adding a condition to delete. Which means the database is probably selecting those records. And I hadn't granted select on the table to the user.

Grant select: grant select on table to username

And it worked.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.