I have a question about grants...

I ran the following command, assuming it would allow me to make any changes to the tables in the public schema:

grant all on all tables in schema public to User1;

However, when I try to add a new column I still get the error message below:

ERROR:  must be owner of table Tab1

I guess I'm just a little misinformed on the purpose of the grant all on all command, and how can I refine this to allow a user to add columns to a table without changing ownership?

1 Answer 1


Right. You cannot GRANT the right to ALTER or DROP a table. Only the table owner or a superuser can do that.

The documentation describes that:

The right to modify or destroy an object is inherent in being the object's owner, and cannot be granted or revoked in itself. (However, like all privileges, that right can be inherited by members of the owning role; see Section 22.3.)

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.