Solved

How can I get rid of ORA-08103 Error?

Posted on 2014-12-28
5
315 Views
Last Modified: 2015-01-08
Dear Experts,

I sometimes get ORA-08103 error for the following PL/SQL code. Could you please help me?

Best Regards.

DECLARE
[There is Single Line Declaration]
BEGIN
EXECUTE IMMEDIATE 'ALTER SESSION SET db_file_multiblock_read_count=16';
INSERT  /*+ APPEND PARALLEL NOLOGGING */  INTO MAINTABLE (<Column List>) SELECT (<Column List>) FROM TMP_TABLE;
COMMIT;
EXECUTE IMMEDIATE 'TRUNCATE TABLE TMP_TABLE DROP STORAGE';
END;

ORA-08103: at line 5. object no longer exists
ORA-06512: at line 3. Sql: DECLARE
0
Comment
Question by:GurcanK
  • 3
5 Comments
 
LVL 76

Accepted Solution

by:
slightwv (䄆 Netminder) earned 500 total points
ID: 40520988
My guess is that some other process has dropped TMP_TABLE before this code has completed the run.
0
 
LVL 28

Expert Comment

by:Naveen Kumar
ID: 40521104
1. Can you give us the line what is in the declare section as well.. may be you could change the name of the variable/mask it accordingly.

2. Also could you please help to add an exception handling section to your plsql block to trap the errors as shown below.

DECLARE
 [There is Single Line Declaration]
 BEGIN
 EXECUTE IMMEDIATE 'ALTER SESSION SET db_file_multiblock_read_count=16';
 INSERT  /*+ APPEND PARALLEL NOLOGGING */  INTO MAINTABLE (<Column List>) SELECT (<Column List>) FROM TMP_TABLE;
 COMMIT;
 EXECUTE IMMEDIATE 'TRUNCATE TABLE TMP_TABLE DROP STORAGE';
Exception
when others then
dbms_output.put_line('In exception section:' );
dbms_output.put_line('sqlcode:' || sqlcode );
dbms_output.put_line(sqlerr:' || sqlerrm );
 END;
0
 

Author Comment

by:GurcanK
ID: 40521388
Thnaks everyone, Slightwv was right, I revealed that another user drops.
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 40522793
Glad to help.  Don't forget to close out the question.
0
 
LVL 76

Expert Comment

by:slightwv (䄆 Netminder)
ID: 40528488
GurcanK,

Can I ask why there was an even split of points here?  I don't see how http:#a40521104 helped answer the question.

I don't have  a problem if you wanted to offer some points as an assist for exception handling but that has nothing to do with what was generating the error.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Wrap Oraccle SQL*Plus executable Command 4 69
case statement in where clause with not exist 15 46
data lookup in Oracle - need suggestions 55 104
database upgrade 8 43
Why doesn't the Oracle optimizer use my index? Querying too much data Most Oracle developers know that an index is useful when you can use it to restrict your result set to a small number of the total rows in a table. So, the obvious side…
Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
This video shows information on the Oracle Data Dictionary, starting with the Oracle documentation, explaining the different types of Data Dictionary views available by group and permissions as well as giving examples on how to retrieve data from th…
This video shows how to copy an entire tablespace from one database to another database using Transportable Tablespace functionality.

867 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

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now