,

ORA-01031: insufficient privileges (when the inline view is updated)

пятница, 18 октября 2013 г. Оставить комментарий

Error: ORA-01031: insufficient privileges (when the inline view is updated).

Cause: This user has no right to "update" on the table joined in the select.

Action:

I got an error when the script is executed.


update (
select emp.comm
from scott.dept dept, scott.emp
where dept.loc = 'CHICAGO' and
emp.deptno = dept.deptno
)
set comm = comm + 100;

User "test" had the following rights:


grant select, update on emp to test;
grant select on dept to test;

To execute update user "test" must have the right to "update" to all fields of tables joined in the select.

grant update (deptno, loc) on dept to test;

Or the entire table:

grant update on dept to test;

UPD: ORA-01031: insufficient privileges (when logging in as sqlplus "/ as sysdba")

0 коммент. »

Оставьте Ваш комментарий