Call now: 252-767-6166  
Oracle Training Oracle Support Development Oracle Apps

Free Oracle Tips

HTML Text

 Home
 E-mail Us
 Oracle Articles


 Oracle Training
 Oracle Tips

 Oracle Forum
 Class Catalog


 Remote DBA
 Oracle Tuning
 Emergency 911
 RAC Support
 Apps Support
 Analysis
 Design
 Implementation
 Oracle Support


 SQL Tuning
 Security

 Oracle UNIX
 Oracle Linux
 Monitoring
 Remote s
upport
 Remote plans
 Remote
services
 Application Server

 Applications
 Oracle Forms
 Oracle Portal
 App Upgrades
 SQL Server
 Oracle Concepts
 Software Support

 Remote S
upport  
 Development  

 Implementation


 Consulting Staff
 Consulting Prices
 Help Wanted!

 


 Oracle Posters
 Oracle Books

 Oracle Scripts
 Ion
 Excel-DB   


 

 

 


 

 

 

 
 

ORA-01410: invalid ROWID tips

Oracle Error Tips by Burleson Consulting (S. Karam)

 

The Oracle docs note this on the ora-01410 error*:

ORA-01410 invalid ROWID
 
Cause: A ROWID was entered incorrectly. ROWIDs must be entered as formatted hexadecimal strings using only numbers and the characters A through F. A typical ROWID format is '000001F8.0001.0006'.
 
Action: Check the format, then enter the ROWID using the correct format. ROWID format: block ID, row in block, file ID.

Oracle Faqs contained this thread concerning ORA-01410, in which a resolution was found:

Question:

From: Poratips

I am running a sql update on a daily basis. Last weekend I got following error:

ORA-01410: invalid ROWID

and the table was locking.

The users were also trying to insert/update the record and it was locking for them. Our DBA found that the update I am running is causing the problem and the lock. This is a very serious situation, as it's causing a problem with our online application.

Could you please tell me what's the wrong with this code? It was running fine, and we only seem to be encountering the problem on Sundays. It's still running ok, but another department wants me to change the code. They are asking me to change the logic so it will not cause the locking problem. How can I prevent the locking?

Here's some more information:

DCS_INVENTORY table has records: 7500
NR_INVENTORY_UPLOAD has records:7000

It's updating almost 5700 records. Here's the update I'm using:

UPDATE
========
UPDATE DCS_INVENTORY A
SET (A.STOCK_LEVEL) =
(select X.STOCK_LEVEL
from NR_INVENTORY_UPLOAD X
WHERE X.inventory_id = A.INVENTORY_ID
and X.STOCK_LEVEL != 0 and STOCK_LEVEL != 0)
where exists (select X.STOCK_LEVEL
from NR_INVENTORY_UPLOAD X
WHERE X.inventory_id = A.INVENTORY_ID
and X.STOCK_LEVEL != 0 and STOCK_LEVEL != 0);
COMMIT;

Answer:

From: Poratips

I have implemented procedure to handle this situation:

CREATE OR REPLACE PROCEDURE SP_STOCK_LEVEL_UP
IS
l_cnt number := 0;
CURSOR C1 IS Select A.stock_level current_level, x.stock_level new_level
From DCS_INVENTORY A , NR_INVENTORY_UPLOAD X
WHERE X.inventory_id = A.INVENTORY_ID
and X.STOCK_LEVEL != 0
and A.STOCK_LEVEL != 0
FOR UPDATE NOWAIT;
BEGIN
FOR CREC IN C1 LOOP
update DCS_INVENTORY
SET STOCK_LEVEL = CREC.NEW_LEVEL
WHERE CURRENT OF C1;
END LOOP;
COMMIT;
dbms_OUTPUT.PUT_LINE('update DONE');
l_cnt := l_cnt+1;
EXCEPTION
WHEN OTHERS THEN
IF SQLCODE = -54
THEN
dbms_OUTPUT.PUT_LINE('YOU CANNOT UPDATE, PLEASE WAIT');
ROLLBACK;
ELSE
raise;
dbms_OUTPUT.PUT_LINE('ERRORS!');
ROLLBACK;
END IF;
END;
/

 

Another user on the Burleson Consulting DBA Forum had the following problem with ORA-01410: invalid ROWID:

Question:

I have a table which is partitioned ,whenever I pass a query I’m getting ORA-01410: invalid ROWID. When I analyze the table, there are no rows in the table invalid_rows. Because of this problem we cannot retrieve data from the table. I’ve created another table and used exchange partition to load the data into the new table, but I'm still receiving the error. How can I check for the invalid rowid? How can I find the rowid with the bloc id in order to find all invalid rows and drop them?

Answer:

The format of the rowid is: block id, row in block, file id. Since you know the block id, you may be able to use a statement such as:

delete from <table> where rowid like '<block id>%'


 

 

Burleson is the American Team

Note: This Oracle documentation was created as a support and Oracle training reference for use by our DBA performance tuning consulting professionals.  Feel free to ask questions on our Oracle forum.

Verify experience! Anyone considering using the services of an Oracle support expert should independently investigate their credentials and experience, and not rely on advertisements and self-proclaimed expertise. All legitimate Oracle experts publish their Oracle qualifications.

Errata?  Oracle technology is changing and we strive to update our BC Oracle support information.  If you find an error or have a suggestion for improving our content, we would appreciate your feedback.  Just  e-mail:  and include the URL for the page.


                    









Burleson Consulting

The Oracle of Database Support

Oracle Performance Tuning

Remote DBA Services


 

Copyright © 1996 -  2012 

All rights reserved.

Oracle © is the registered trademark of Oracle Corporation.


   

 

  
 

 
 
 
 
Oracle performance tuning software
 
 

 

 
 
 
Oracle performance Tuning 10g reference poster
 
 
 
Oracle training in Linux commands
 
Oracle training Excel
 
Oracle training & performance tuning books