Oracle compile package: table has errors - oracle

I have a big problem on my database.
I have a Oracle 9i database and a Oracle 11g database.
I have a package with a stored procedure on my 9i database. Inside a have a very simple select like :
select * from my_table_on_my_11g_database#MYDBLINK;
When I'm trying to compile the package containing this query, I have the following error :
[Error] ORA-04063 (337: 20): PL/SQL: ORA-04063: table "my_table_on_my_11g_database" has errors
When I'm trying to execute the query using Toad in a editor, it works fine.
So, I don't know what is the problem.
It's about roles, rights ?
We just installed this 11G database, before we had a 9i database and it worked fine. I'm guessing I'm missing some grants ?
Thanks for any idea.
C.C.

Finally it works. I've created a new public DBLink and it works.
It was maybe because the DBLInk was created before with the old database, I don't know.
Thanks for the answers.

Related

ORA-01219 - "database or pluggable database not open: queries allowed on fixed tables or views only"

I've just installed oracle database 18c on my windows 10 machine. Then I used Oracle SQL Developer to login to the database that I've created during the installation with connection information below:
The connection was successful and when I tried to open the Tables, it showed an error OCA-01219:
I've found this solution:
ORA-01219: database not open: queries allowed on fixed tables/views only
that trying to make the database open. I have tried this but still no success, my database status:
Can anyone please help to to solve this problem? Thank you very much in advanced.
I run into the same problem after having to restart the Oracle Service. The problem was the state of the pluggable database not that of the instance itself, which was "open" like in your case.
The following command worked for me (please replace "orclpdb" with your pluggable DB name):
alter pluggable database orclpdb open;
If output of 'select status from v$instance' is open, can you please execute below query and let me know the out put:
select name, open_mode from v$database;
Also, please let me know if you are trying to connect pluggable database. In case you are connecting to pluggable db, then run below query:
alter session set container='';
Then after apply above approach. please let me know if any query further

Error while runneing select query in sql developer

I am using Oracle SQL Developer version 4.1.0.19.
So this can be a very simple issue but I cannot seem to find the solution anywhere as I have just started using SQL Developer.
I type in this query
create table Student(Stu_id INTEGER,Stu_name VARCHAR(60),Stu_email VARCHAR(60))
select * from Student
And when I Run the SELECT query, I get an error something like this:
Method oracle/jdbc/driver/T4CCallableStatement.isClosed()Z is abstract
I have no idea as to why this is happening , this may be very stupid but I cannot seem to find a solution.
BTW I am using Oracle 11g version.
How did you install SQL Developer? Can you download the zip off of OTN and extract it to a fresh directory and try running it from there?
Your error message indicates something VERY bad is wrong with one of the drivers. Which makes me wonder if you messed with one of the JARs or are attempting to use an old Oracle Client with a THICK connection.

SQL data extracts works in Oracle 11g but not Oracle 12c

When I execute the following SQL using TOAD against an Oracle 11g database, the fully formed XML is returned successfully:
With T As (SELECT dbms_xmlgen.getxml('SELECT m.trans_message FROM xml_nodes_ams_in a, message m WHERE a.id = m.msg_id AND a.UPN IN(''A30971016528VE8K'',''A30971016529VE84'') ORDER BY a.upn ASC'
) As output_xml from dual
) select dbms_xmlgen.Convert(output_xml,1) from T
However, when I execute the exact same SQL against our newly installed Oracle 12c database, some of the XML data appears to be missing (around 5000 characters).
I have discussed this with the DBA who reckons its a client issue rather than a database issue as he says there is no setting against the database that would cause this.
Has anyone got any advise on how I can progress this issue?
I raised a service request with Oracle and they came back to me and advised that there is a bug with the dbms_xmlgen.Convert function within Oracle 12.1 that was fixed in Oracle 12.2. Basically the function fails with XML greater than 120 KB.

My SSIS package using ole db command to update oracle, the update commands won't work

BIDS 8.0
oracle 11.g client is installed. the original server was 11g and it worked. we upgraded the server to oracle 12c. all ole db update commands will not work. There is no error from the output, just the table data not updated. any ideas?
Try this
CREATE Procedure and sen parameters to it, and handle the Update operation in Procedure
Do not forget use commit end of the dml statament

Cannot execute procedure in oracle 10g says Table or View does not exist

I have an Oracle database which was already created and designed by someone else previously, in my company. My problem is that some procedures are not executing. I'm getting the error:
Table or procedure or view does not exist
But, I can see those procedures from Toad. I already tried to grant some privileges from sysdba, the result is the same; I get the same error.
Any help would be highly appreciated.

Resources