I have a package that doesn´t compile, showing this error PLS-00302, pointing to a specific table I created.
Well, I have granted this table to public with grant option, to test.
I recompile the package, but yet its not working, with the same issue.
Does anybody have any suggestion?
Thanks!
Related
I've been trying for a while now to access an oracle DB directory I have created.
I've granted all permissions to the schema I want to access the directory from, but still Im getting the same error: "ORA-29280:invalid directory path".
I've checked the directory multiple time on my server, and it's everything as it should be, carefully checked, and still getting the same error.
I try to execute this example code from the schema I need to create the file from, to create a file in my directory:
DECLARE
l_file utl_file.file_type;
BEGIN
l_file := utl_file.fopen( 'DIRECTORIO_DATO_EXT', 'example_file.txt', 'W' );
utl_file.put_line( l_file, 'Example file.' );
utl_file.fclose( l_file );
END;
And the same error appears.
But when I execute the very same code from the SYS user as SYSDBA, the procedure completes without error, and the file is created in the server.
Please note that I've added ALL privileges to the user I want to access the directory from:
GRANT ALL ON DIRECTORY DIRECTORY_DATO_EXT TO MY_SCHEMA;
GRANT READ ON DIRECTORY DIRECTORY_DATO_EXT TO MY_SCHEMA;
GRANT WRITE ON DIRECTORY DIRECTORY_DATO_EXT TO MY_SCHEMA;
GRANT CONNECT ON DIRECTORY DIRECTORY_DATO_EXT TO MY_SCHEMA;
Also, from the server OS I've granted all permissions to the folder where the directory is pointing, and even tried to add the oracle user to the root user group to see if that worked, but still nothing.
I'll appreciate any help.
Regards.
Ok, so I just found out what was my problem:
I created a DBLink a few days ago, and updated ALL the synonyms from the main database so I could access my DBLink. When I did that , I did it for ALL synonyms, included UTL_FILE synonym, resulting in something like this:
CREATE OR REPLACE SYNONYM MY_SCHEMA.UTL_FILE FOR SYS.UTL_FILE#DBLink;
And as it turned out, the "#DBlink" was the problem, cause it was pointing at a specific schema (not sys), making my procedure unable to find the UTL_FILE utility.
Hope this helps someone in the future!
When I am running the below query from my user account then getting the subject error.
Select * from CMD.CMD_AUDIT;
When I ran the same query from super user then able to run successfully.
I checked old articles regarding same, they said this is the version issue with toad. But in my case using same toad version, only the issue is with differ user account.
Could you please help me in this?
I faced with the problem at Toad 11.6.1 I cannot open package body of Oracle database on Toad 11.6. So when I click button Toggle Spec/Body The following info was showing:
Cannot navigate to package body because this spec has no body
But when I connect to the same DB with with the same username with TOAD 10.1.1 everything is ok. It means that I have access to see the package and it's body. I have no idea what maybe the problem.
I assume the package isn't owned by the user you're connecting as?
If so, TOAD has an option to use DBA views which is NOT checked by default. Is it checked in your 11.6 version? if not, then unless you have DEBUG privilege on the package, you won't see the body.
I'm at my wits' end with this error.
I have a view which uses a function contained in a package in another schema. I've created a synonym to said package, and on my local dev DB, the view compiles correctly. On the build server, the view gives compilation errors.
When I run the select of the view manually, Oracle throws an ORA-00904 error on the synonym in the query. I just can't understand why it works in one place and not the other. The code on both servers is identical, as it's coming from our source control repository.
As phlogratos suggested, it was a privileges issue. As the user didn't have execute permissions on the package in the separate schema, it was causing this error.
The underlying problem was an issue with our script that applies grants, but it's good to know that references like this without permissions fail in this manner.
I can not explain this, i keep gettign the Message "Ora942-table or view does not exist" from one pc while i dont get it from the other one, both access the same Schema and Database and has the same alias in tnsnames.ora.
The table exists in the Database, the Schema name is the write one.
Any Idea what could be the reson for that?
thank you
Found it.
On the PC where it didnt work the BDE Configuration was different!
Configuration->Driver->Native->Oracle->Driver Flags was Empty. It should be set to 1