?
Solved

Oracle - Stored Procedure Privilge access

Posted on 2016-11-20
3
Medium Priority
?
88 Views
Last Modified: 2016-11-21
So I created a stored procedure to insert/update some other tables.  After creating the stored procedure and compiling it, I am getting error that I do not have access.  However, I am able to update/insert to those tables with just the query before making the SP.  Is there anything special that needs to be done to allow the SP to update those tables?
0
Comment
Question by:holemania
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 74

Accepted Solution

by:
sdstuber earned 2000 total points
ID: 41895278
the stored procedure needs to be owned by the same schema that owns the tables

or, that schema needs to be granted insert/update privileges on those tables directly (i.e. NOT through a role)


another option, probably not what you want...

that procedure could be recompiled with "authid current_user" option, but using this route generally complicates things.
0
 

Author Comment

by:holemania
ID: 41896194
Thank you.  That make sense.  I will try that and update later.
0
 

Author Closing Comment

by:holemania
ID: 41896527
Thank you.  That was it.
0

Featured Post

Moving data to the cloud? Find out if you’re ready

Before moving to the cloud, it is important to carefully define your db needs, plan for the migration & understand prod. environment. This wp explains how to define what you need from a cloud provider, plan for the migration & what putting a cloud solution into practice entails.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Cursors in Oracle: A cursor is used to process individual rows returned by database system for a query. In oracle every SQL statement executed by the oracle server has a private area. This area contains information about the SQL statement and the…
If you find yourself in this situation “I have used SELECT DISTINCT but I’m getting duplicates” then I'm sorry to say you are using the wrong SQL technique as it only does one thing which is: produces whole rows that are unique. If the results you a…
Via a live example, show how to take different types of Oracle backups using RMAN.
This videos aims to give the viewer a basic demonstration of how a user can query current session information by using the SYS_CONTEXT function
Suggested Courses

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question