Ask the Expert

Insufficient privileges to create views

According to our DBA, I have the permission to create views. However, when I am creating one, it gives me error 'ORA-01031: insufficient privileges'. Could you kindly give some expert advice on what might be the cause. I am currently using TOAD to connect to Oracle DB.

    Requires Free Membership to View

Your first idea that you need the CREATE VIEW system privilege is correct. If you do not have this system privilege, then you will receive the ORA-1031 error when you try to create the view. If you have been granted CREATE VIEW and still cannot create your view, then you need to dig further.

When you create the view, you rely on one or more underlying objects of that view. These objects can be other tables, views, synonyms, functions, etc. And sometimes, these objects depend on other objects. For instance, the synonym your view is trying to reference points to a view in another schema that uses a table in that schema. You need to make sure that you have the appropriate permissions on the underlying objects of your view, and any objects that those underlying objects depend on. If you do not have permissions on any of these objects, then you will receive the ORA-1031 error.

This was first published in December 2004

There are Comments. Add yours.

 
TIP: Want to include a code block in your comment? Use <pre> or <code> tags around the desired text. Ex: <code>insert code</code>

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
Sort by: OldestNewest

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to: