Issue of insufficient privileges

Could anyone help on this?

create or replace procedure

as

txt varchar (100): ='GRANT SELECT ON "RADB. "" NOV14 ' to RADB_READ_ONLY';

Begin

run immediately (txt);

end;

SQL > execute test

START the test; END;

*

ERROR on line 1:

ORA-01031: insufficient privileges

ORA-06512: at "DRAI01. TEST', line 5

ORA-06512: at line 1

But it works.

Begin

run immediately ('GRANT SELECT ON "RADB".) "" NOV14 "to RADB_READ_ONLY"); "

end;

Kind regards

VN

Please explain why it is necessary to publish the GRANT via EXECUTE IMMEDIATE.

all GRANT & CREATE statements should be made through SQL static during the upgrade of the application.

BTW, object name should NEVER contain DATE value; as "NOV14!

Is not consistent with the normal form of third & must be an additional column in another table!

Tags: Database

Similar Questions

  • ORA-01031: insufficient privileges while selectin view belongs to another schema in oracle database 11g

    Hello

    DB version 11.2.0.3.0

    We have a few views resides in the application schema, we cerated user and granted select on the view through the roles.

    but the user becomes ORA-01031: insufficient privileges when accessing the content view

    appreciated inputs

    BR

    Praaksh GR

    > I issued a grant select on Z.table - X with the option grant.

    This isn't what you need - you should

    Grant select on Z.table y with the option grant.

    Grant select on Y.view to X;

  • Download "error: ORA-01031: insufficient privileges" when try to add relief of database

    Hi all

    I get insufficient privileges error when I added a standby database to dg configuration. I read some blog and he said that dgmgrl does not support os authentication, which means that I need to connect with sys and password. But I found that if I keep standby and primary SIDs are the same, the error will not occur even if I don't provide a password. Anyone know the reason? And no workaround?

    The process as follows:

    main SID: orcl ensures sid: prxx

    connect to "dgmgrl / '.

    Run ' add the database ' prxx_stby "as an identifier of connection is"prxx_stby"

    Download:

    Error: ORA-01031: insufficient privileges

    Failed.

    But if sid main: orcl ensures sid: orcl

    connect to "dgmgrl / '.

    Run ' add the database ' orcl_stby "as an identifier of connection is"orcl_stby"

    Download:

    Database "orcl_stby" added

    Liz

    I think still you can connect as "dgmgrl /", but its recommended to use "dgmgrl sys / * '.

    As rchem has said, there can be question of password. It doesn't matter whether the SID is the same or not primary and standby so different locations. So the best practice is to connect to the database from the primary server before using Oracle net service and test whether you connect or not.

    Ex: Prim_host > sqlplus sys/***@stby as sysdba

    There are a lot of possible issues

    -Missing or invalid password file

    -Service name is not registered with earphone

    -service incorrect, mentioned in the tns names

    and so many things, overlaps with these things.

  • Error ORA-01031 insufficient privilege when selecting a view

    OK, I think it's maybe a stupid question, but I can't understand it:

    The user John won the right to SELECT (directly, not by a database role) to the FRED.table1 schema.
    John user can issue select * from FRED.table1; and it works very well.

    User John then got the right to SELECT (directly, without going through a database role) to the schema
    MARK.view1;

    MARK.view1 selects only FRED.table1. No other table is in the View1.
    Schema MARK questionable views successfully. SELECT * FROM View1 returns results.
    I also checked the MARK scheme to ensure that she got the select on FRED.table1 directly that he has.

    Now, when you're logged in schema John, I try SELECT * to SCORE. VIEW1; and I get error ORA-01031 insufficient privileges.

    I don't know how to solve this. If John is granted SELECT a TABLE, it works of course but I don't want John to have this powerful private.

    As a reminder, SELECT these two brands a John. View1 and the table View1 selects from (FRED. (TABLE 1).
    John can select FRED. Table1: no problem but does not receive a privilege error even if John has SELECT on the BRAND. VIEW1.

    Any thoughts?

    Oh, Oracle 10.2.0.4 EA

    JSebastian wrote:
    OK, I think it's maybe a stupid question, but I can't understand it:

    The user John won the right to SELECT (directly, not by a database role) to the FRED.table1 schema.
    John user can issue select * from FRED.table1; and it works very well.

    User John then got the right to SELECT (directly, without going through a database role) to the schema
    MARK.view1;

    MARK.view1 selects only FRED.table1. No other table is in the View1.
    Schema MARK questionable views successfully. SELECT * FROM View1 returns results.
    I also checked the MARK scheme to ensure that she got the select on FRED.table1 directly that he has.

    Now, when you're logged in schema John, I try SELECT * to SCORE. VIEW1; and I get error ORA-01031 insufficient privileges.

    I don't know how to solve this. If John is granted SELECT a TABLE, it works of course but I don't want John to have this powerful private.

    As a reminder, SELECT these two brands a John. View1 and the table View1 selects from (FRED. (TABLE 1).
    John can select FRED. Table1: no problem but does not receive a privilege error even if John has SELECT on the BRAND. VIEW1.

    Any thoughts?

    Oh, Oracle 10.2.0.4 EA

    Are you sure that John was granted select on Mark.view1? In order for that to work, Mark would have had to select on the WITH GRANT OPTION Fred.table1... otherwise the grant to fail and then John would not be able to select the view because the grant was never issued successfully.

    Here is a basic test case (which I think is consistent with what you said) to make it work.

    drop user u1 cascade;
    drop user u2 cascade;
    drop user u3 cascade;
    
    create user u1 identified by u1;
    grant connect, resource to u1; 
    
    create user u2 identified by u2;
    grant connect, resource, create view to u2;
    
    create user u3 identified by u3;
    grant connect, resource to u3;
    
    connect u1/u1@orcl
    create table test1 (col1 number);
    grant select on test1 to u2 with grant option; --> this is the important part
    grant select on test1 to u3;
    
    connect u2/u2@orcl
    create view test2 as select * from u1.test1;
    grant select on test2 to u3;
    
    connect u3/u3@orcl
    select * from u2.test2;
    
  • ORA-01031: insufficient privileges from a function

    Deploy_ctl.fun_stg_raw (NO_DAYS in NUMBER, of the FUNCTION to CREATE or REPLACE
    col_date DATE)

    RETURN NUMBER
    AS

    RTN_SUCCESS CONSTANT NUMBER (1): = 0;
    RTN_FAILURE CONSTANT NUMBER (1): = 1;
    RTN_NON_FATAL NUMBER (1) CONSTANT: = 2;


    CURSOR stg_raw_cur IS
    SELECT RAW_STG_ID,
    DEVICE_CD,
    MODEL_VERSION,
    PLATFORM_CD,
    PROFILE_COOKIE,
    LOCATION_CD,
    SAMPLE_RATE,
    EVENT_TYPE_CD,
    EVENT_DATE_TIME,
    EVENT_SPECIFIC,
    BATCH_ID,
    DWH_ARVL_DT,
    DWH_ARVL_DT_ID,
    Dwh_stg.stg_raw DWH_CREATE_DT
    When trunc (to_date (EVENT_DATE_TIME, "YYYYMMDD"T"hh24:mi:ss"Z"')) = to_date (' 04/28/2014 ',' mm/dd/yyyy')
    order of batch_id CSA;


    TYPE stgrawarr IS TABLE OF stg_raw_cur % ROWTYPE;

    stg_raw_rec stgrawarr;

    l_batch_id NUMBER: = 0;
    v_ctr NUMBER: = 1;
    l_temp_batch_id number: = 0;
    l_date VARCHAR2 (2000);

    BEGIN

    run immediately 'truncate table t_stg_raw;

    OPEN stg_raw_cur.
    LOOP
    Get the stg_raw_cur COLLECT LOOSE stg_raw_rec LIMIT 100;
    OUTPUT
    WHEN stg_raw_cur % NOTFOUND;
    END LOOP;

    CLOSE Stg_raw_cur;

    I'm in stg_raw_rec.first... stg_raw_rec. Last
    loop

    -dbms_output.put_line (' batch code is ' | .batch_id stg_raw_rec (i));
    IF l_temp_batch_id! = stg_raw_rec (i) .batch_id
    then

    l_batch_id: = stg_raw_rec (i) .batch_id - v_ctr;
    l_temp_batch_id: = stg_raw_rec (i) .batch_id;
    * dbms_output.put_line ('Différent' |) "v_ctr" |
    v_ctr | ' ' || l_batch_id |
    ' ' || stg_raw_rec (i) .batch_id | ' ' ||
    stg_raw_rec (i). EVENT_DATE_TIME) ;*/
    v_ctr: = v_ctr + 2;

    end if;

    1.no_days j
    loop
    l_date: = to_char (to_date (to_date (substr (stg_raw_rec (i). (EVENT_DATE_TIME, 1, 8), 'YYYYMMDD')-j |
    'T' ||
    substr (stg_raw_rec (i). EVENT_DATE_TIME, 10, 8).
    ('Z', "DD-MON-RR"T"HH24:MI:SS 'Z'"), "YYYYMMDDYY"T"HH24:MI:SS 'Z'");
    dbms_output.put_line (' l_batch_id ' | l_batch_id |)
    "stg_raw_rec (i) .batch_id | stg_raw_rec (i) .batch_id |

    "l_date" | l_date);
    end loop;

    l_temp_batch_id: = stg_raw_rec (i) .batch_id;
    commit;
    end loop;

    RETURN RTN_SUCCESS;

    EXCEPTION
    WHILE OTHERS THEN
    -Insert in the (current) error log table
    DBMS_OUTPUT. PUT_LINE ('SQLCODE' |) SQLCODE. ' '|| SQLERRM);

    RETURN RTN_FAILURE;

    END fun_stg_raw;
    /
    DISPLAY ERRORS;
    /


    I can execute SQL statements on its own as a user DEPLOY_CTL but when compiling the function, he throws ORA-01031: insufficient privileges error.

    Thank you

    This may be infamous granting by the issue of the role. You need the explicit subsidies. For more information see Re: compile errors
    You can use the VALUE NO ROLE and then try to run the SQL to check.

  • ORA-01031: insufficient privileges when you try to run a proc

    I have a procedure called KILL_MY_SESSION that is defined with a value of DEFINE AUTHID

    The schema JOHN belonged procedure. The procedure makes several calls to PL/SQL DBMS_SQL package.
    The last thing that not with DBMS_SQL proceedings concern an ALTER SYSTEM KILL SESSION statement.
    Schema JOHN has privileges to kill a session in the database.
    If I log in the scheme of JOHN, I can issue the statement ALTER SYSTEM KILL SESSION successfully.
    Also, when you are logged in the scheme of JOHN, I can run the KILL_MY_SESSION procedure.

    Now I have the ISTO schema. I got ISTO privileged EXECUTE on the JOHN. Procedure KILL_MY_SESSION.
    Since JOHN. KILL_MY_SESSION is a privilege of rights DEFINERs, if RIGHTS shouldn't be able to execute the procedure correctly and kill a session?

    This is an output of the session of the ISTO when you try to run JOHN. KILL_MY_SESSION:

    SQL > conn oifs@dbname
    Enter password: *.
    Connected.
    SQL > 500 fixed lines
    SQL > select username, osuser, sid, serial #.
    2 session $ v
    3 where username = "OIFS."

    USERNAME OSUSER SID SERIAL #.
    ------------------------------ ------------------------------ ---------- ----------
    OIFS administrator 142 325
    OIFS administrator 139 613

    SQL > exec ('142 ', 325') john.kill_my_session
    BEGIN john.kill_my_session ('142 ', 325'); END;

    *
    ERROR on line 1:
    ORA-01031: insufficient privileges
    ORA-06512: at "SYS." DBMS_SYS_SQL", line 1204
    ORA-06512: at "SYS." DBMS_SQL", line 323
    ORA-06512: at "EIADBA. KILL_MY_SESSION', line 20
    ORA-06512: at line 1


    Someone at - he a clue as to what I'm doing wrong?
    View DBA_PROCEDURES, here's the record for KILL_MY_SESSION


    OWNER
    ------------------------------
    OBJECT_NAME
    --------------------------------------------------------------------------------
    OBJECT_TYPE AUTHID
    ------------------- ------------
    JOHN
    KILL_MY_SESSION
    DEFINE PROCEDURE

    I mean the privilege of system alter directly, not through roles.

    GRANT ALTER SYSTEM TO JOHN;
    

    Please read the articles below, you should restrict the sessions that can be killed, according to what will be your implementation.

    It could be useful.
    http://asktom.Oracle.com/pls/asktom/f?p=100:11:0:P11_QUESTION_ID:226613885088
    http://DBA-Oracle.com/t_granting_alter_system_kill_session.htm

  • I tried to switch from Firefox 5 to 8 of Firefox, but a message box indicates that I have insufficient privileges to install. How can I continue?

    I received the alert to update Firefox, but during download and try to install, by moving the Firefox to the Applications icon, receive the message "insufficient privileges" box

    If he has problems with the update or the permissions then simpler is to download the full version and trash the version currently installed to do a clean install of the new version.

    Download a new copy of the Firefox program and save the file on the desktop disk image (dmg)

    • Trash the present application Firefox to do a clean (re-) install
    • Install the new version you downloaded

    Your profile data is stored in the Firefox profile folder, so you will not lose your bookmarks and other personal data if you uninstall and (re) install Firefox.

  • Tedious Error Message When you install Itunes "the installer has insufficient privileges to access this directory: C:\Program Files\Quick Time\QTSystem.»

    Hi, I tried to update my iTunes a day and when he made an error appeared. Now, today I uninstalled both iTunes & Quicktime, I don't remember what the first said (before finding out the programs were installed yet) but after I went back uninstalled them I tried to reinstall again (in the hope that it would work) and this message popped up.

    The installer has insufficient privileges to access this directory: C:\Program Files\Quick Time\QTSystem. The installation cannot continue. Log in as administrator or contact your system administrator.

    * I'm already logged as administrator.

    Could you please help me understand what the problem is? Thank you!

    Hello

    Try right click on setup.exe itunes then run as adminintrator

    If this does not work, try this

    Follow the information from apple to the link below

    Remove and reinstall iTunes, QuickTime, and other software components for Windows Vista or Windows 7

    http://support.Apple.com/kb/HT1923

    and or ask for their support of itunes

    http://www.Apple.com/support/iTunes/

    Also try the discussions of apple itunes

    http://discussions.Apple.com/category.jspa?categoryID=149

  • I have administrator privileges, but when I run CHKDSK it says access denied due to insufficient privileges.

    I have administrator privileges, but when I run CHKDSK it says access denied due to insufficient privileges. You have to invoke this utility in elevated mode.

    How can I fix it?

    Hello

    1. what prompted to run chkdsk on your computer?

    To work with this problem, refer to these methods.

    Method 1:

    I suggest that you disable the antivirus software temporarily and try to run chkdsk on your computer.

    http://Windows.Microsoft.com/en-us/Windows7/disable-antivirus-software

    Warning:
    Antivirus software can help protect your computer against viruses and other security threats. In most cases, you should not disable your antivirus software. If you need to disable temporarily to install other software, you must reactivate as soon as you are finished. If you are connected to the Internet or a network, while your antivirus software is disabled, your computer is vulnerable to attacks.

    Method 2:

    You can check disk errors using the command-line of the system recovery options in Windows 7.

    What are the system recovery options in Windows 7?

    http://Windows.Microsoft.com/en-us/Windows7/what-are-the-system-recovery-options-in-Windows-7

    To open the System Recovery Options, see the section: to open the menu system on your computer Recovery Options

    Important: when running chkdsk on the drive hard if bad sectors are found on the disk hard when chkdsk attempts to repair this area if all available on which data may be lost.

    Check if it helps.

  • Insufficient privileges. I can't install Adobe Flash!

    I can't install Adobe Flash Player due to insufficient privileges.

    I'm the only one on my computer. I am the admin. I downloaded the Adobe Flash player.exe and right click 'run as Admin '.

    Always said that I don't have sufficient privileges. It becomes so boring. Someone please help me with this task easy.

    How to become admin with these sufficient privileges?

    Solved, kind of...  At this point, I am confident that the problem was caused in fact viruses that I found on the computer.  Once I removed the viruses I then applied a restore point (I had to go back 30 days). Now, I could install Flash 11 and then re - apply Windows updates.

    I was never determined the exact cause of the error, so I don't have any advice for someone who doesn't have to fall back on a restore point.

  • the installer has insufficient privileges to access this directory: c:\Program file\msi\easyviewer

    the installer has insufficient privileges to access this directory: c:\Program file\msi\easyviewe how to accept. How active upgrade windows 7 home top.

    If you trust the program you are trying to install, right-click on the installation .exe file and select run as administrator.

  • Target schema differs from the scheme of work: insufficient privileges

    I created a scheme of work called ODI_STAGE in the same database where is my target db.

    In topology about dataserver ODI I gave details of my scheme target (user) say ODI_Target.

    ODI_Target does not have the privileges on ODI_Stage.So during execution of mapping it throw error saying insufficient privilege.

    Please let me know how to solve this and what a privilege to command that I need to run?

    Thanks Prashant da Silva and Aramast Oghiguian for your help and suggestions.

    What I did that I've given DBA privileges to ODI_STAGE and serving as ODI_STAGE the user to the database server target. In this way, got problem solved and my manager has been fine with it.

  • Create table ORA-01031: insufficient privileges

    SQL > indicate user USER is 'TEST_RPT.

    SQL > CREATE TABLE mytest (id NUMBER); - it does not work

    CREATE TABLE mytest (id NUMBER)

    * ERROR at line 1: ORA-01031: insufficient privileges

    SQL > CREATE TABLE TEST_RPT.mytest (id NUMBER).

    Table created. SQL >


    SQL > select * from session_privs;

    PRIVILEGE

    ----------------------------------------

    ANY PROCEDURE DEBUG

    DEBUGGING SESSION CONNECT

    CREATE INDEXTYPE

    OPERATOR TO CREATE

    CREATE THE TYPE

    CREATE THE TRIGGER

    CREATE PROCEDURE

    CREATE SEQUENCES

    CREATE VIEW

    CREATE SYNONYM

    CREATE THE CLUSTER

    CREATE TABLE

    UNLIMITED TABLESPACE

    ALTER SESSION STATEMENT

    CREATE SESSION

    Try this:

    SELECT USER, SYS_CONTEXT('USERENV','CURRENT_SCHEMA') FROM DUAL;

    The two identical values? CURRENT_SCHEMA is what will determine the owner of the table you create, if you do not specify an owner.

    This can be changed by

    ALTER SESSION SET CURRENT_SCHEMA = whatever_you_want_it_to_be;

  • Creating the javax/activation/ActivationDataFlavor class error ORA - 01031: insufficient privileges

    Hi all

    I created mail.jar is correctly loaded in the database, but while loading activation.jar I get the following error.

    Version of Oracle 11.2.0.4.0 database.

    loadjava.bat u sys / * o - r - v f - noverify-synonym g public D:\EXCEL_ORACLE_DIR\activation.jar

    arguments: '-u' ' sys / *' 'o' '-r' '-v' '-f' '-noverify' '-synonym ' "-g' 'Public' 'D:\EXCEL_ORACLE_DIR\activation.jar'"

    creation: resource META-INF/MANIFEST. MF

    loading: resource META-INF/MANIFEST. MF

    creation: resource META-INF/mailcap.default

    loading: resource META-INF/mailcap.default

    creation: resource META-INF/mimetypes.default

    loading: resource META-INF/mimetypes.default

    creation: javax/activation/ActivationDataFlavor class

    loading: javax/activation/ActivationDataFlavor class

    Error when creating class javax/activation/ActivationDataFlavor

    ORA-01031: insufficient privileges

    ORA-06512: at line 1

    creation: class javax/activation/CommandInfo

    load: class javax/activation/CommandInfo

    Error when creating class javax/activation/CommandInfo

    ORA-01031: insufficient privileges

    ORA-06512: at line 1

    Something that I missed.

    Thank you all for your response.

    I connect sys as sysdba.

    I checked the sys schema which classes activation.jar is already there that is why it is showing error.

  • ORA-01031: insufficient privileges when granted access privileges to a new user

    Hello.

    When you are connected to a SYSTEM, I'm trying to create a new user and give him all the system privileges, but do so always the following error message appears:

    Cannot process the SQL command

    -

    Error at startup to the line: 123 to orders.

    SYSDBA GRANT TestUser

    Error report-

    SQL error: ORA-01031: insufficient privileges

    01031 00000 - "insufficient privileges".

    * Cause: An attempt was made to execute a database operation without

    the necessary privileges.

    * Action: Ask your database or the designated security administrator

    administrator to grant you the required privileges

    After clicking OK, the user is still being created, but it lacks many privileges to access.

    How can I solve this problem?

    I use Oracle SQL Developer version 4.1.2.20 and Oracle database 11g of the express edition.

    Connect as SYS, not SYSTEM to grant this priv

    Give him with extreme prejudice - it is powerful

    Note in the 12 c database we have stopped a lot of the administrative bits of the SYSDBA role in less powerful. This gives you more flexibility on who can do what in your database

    https://docs.Oracle.com/database/121/DBSEG/authorization.htm#DBSEG578

Maybe you are looking for