Home » SQL & PL/SQL » SQL & PL/SQL » Create View Problem
Create View Problem [message #229934] Tue, 10 April 2007 06:11 Go to next message
fcatak
Messages: 16
Registered: March 2007
Location: turkey
Junior Member
Hi
I have problem. When I try to create a view from another schema's view which is accessible from mu user, Oracle gives an error "Insufficient Priviligies"
CREATE OR REPLACE VIEW VIEW_TMP01 AS
SELECT * FROM IFSAPP.CUST_ORD_CUSTOMER c


But I can create view this
CREATE OR REPLACE VIEW VIEW_TMP01 AS
SELECT 1 FIELD1  FROM DUAL


And also
SELECT * FROM IFSAPP.CUST_ORD_CUSTOMER c


works.
What is the problem.

http://fcatak.spaces.msn.com
Re: Create View Problem [message #229940 is a reply to message #229934] Tue, 10 April 2007 06:34 Go to previous messageGo to next message
Michel Cadot
Messages: 64103
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
You must have select privilege on the underlying objects directly granted to you.

Regards
Michel
Re: Create View Problem [message #229949 is a reply to message #229934] Tue, 10 April 2007 07:02 Go to previous messageGo to next message
fcatak
Messages: 16
Registered: March 2007
Location: turkey
Junior Member
but
SELECT * FROM IFSAPP.CUST_ORD_CUSTOMER c
works
Re: Create View Problem [message #229950 is a reply to message #229949] Tue, 10 April 2007 07:03 Go to previous messageGo to next message
Michel Cadot
Messages: 64103
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Because you have the privilege through a role.
Re: Create View Problem [message #229952 is a reply to message #229950] Tue, 10 April 2007 07:10 Go to previous messageGo to next message
Maaher
Messages: 7062
Registered: December 2001
Senior Member
You can test that by doing:
SQL> SET ROLE NONE;

Role set.

SQL> _your_query_here_;
If the query fails, you have the privilege through a role.

MHE
Re: Create View Problem [message #229962 is a reply to message #229934] Tue, 10 April 2007 07:26 Go to previous message
fcatak
Messages: 16
Registered: March 2007
Location: turkey
Junior Member
Yes you right. I have the privilege through a role. It works now. Thanks

http://fcatak.spaces.msn.com
Previous Topic: Split string to rows
Next Topic: sql code asking for username and password when running a batch file
Goto Forum:
  


Current Time: Sat Dec 03 06:03:51 CST 2016

Total time taken to generate the page: 0.11461 seconds