ORA-01403 No data found on INSERT
Hello,
We have a program that does a lot of inserts in a simple table. Every now and then, we get the error ORA-01403 NO DATA FOUND.
Our program is written in Delphi 7. We use the Oracle Data Access Components (ODAC, by CoreLab) to access the database.
I read in the Oracle docs that the error is generated by a select statement, but we use something like:
"insert into BLAH (BLAH_ID, BLAH_VAL, BLAH_STATUS) values (15,'Test',10)"
The table (BLAH) and all related tables do not have triggers (with "select into"). We don't use stored procedures or functions.
I activated AUDIT, but apparently this error isn't logged in the AUDIT-tables (others are, so the AUDIT works).
Anyone any suggestions?
Regards,
Gert
Nope, no triggers at all...
It may be worth mentioning that our programs for this particular customer have been changed recently for use with ODAC. Before, we used the Borland Database Engine (BDE). The database is still an Oracle 8.05 and the customer is planning to do an upgrade. But before upgrading Oracle we had to convert our programs (to use ODAC instead of BDE) and test run them to see if this change was OK. Apparently it isn't...
We have a lot of experience with the combination Delphi 7 / ODAC / Oracle (even 8.05), without encountering this problem.
Is there any other way (other than audit) to see what object or statement exactly generated the ORA-01403?
Regards,
Gert
Similar Messages
-
AFTER INSERT TIGGER, ora-01403: no data found error
Hi all,
I'm trying to create a fairly simple trigger which fires after an insert on a table.
The trigger is based on a function, defined within a package. The function is as follows...
FUNCTION check_contract_length (V_playerId IN NUMBER)
RETURN BOOLEAN
IS
months NUMBER;
months2 NUMBER;
BEGIN
SELECT months_between(contract_end, contract_start), contract_length
INTO months, months2
FROM player
WHERE playerId = v_playerId;
IF months <> months2 THEN
RETURN (true);
END IF;
RETURN (false);
END check_contract_length;The trigger operates when an insert is made on to the player table, it as defined as follows...
CREATE OR REPLACE TRIGGER play_ins_con
AFTER INSERT ON player
FOR EACH ROW
DECLARE
isover BOOLEAN;
BEGIN
IF INSERTING THEN
isover := player_constr_pkg.check_contract_length(:new.playerId);
IF isover THEN
RAISE_APPLICATION_ERROR(-30001, 'Contract length incorrect');
END IF;
END IF;
END play_ins_con;My problem is, is that every time I try to insert a row into the player table, the trigger fires and produces a "ora-01403: no data found" error. I was under the impression that as the trigger fires after an insert, this shouldn't be a problem.
I'm also aware that this constraint can probably be implemented using a CHECK constraint, however it would be a learning curve for me to work it out this way.
Any help would be much appreciated!!
Cheers guys.I'm also aware that this constraint can probably be implemented using a CHECK constraint,
however it would be a learning curve for me to work it out this way.Starting out by doing stuff the wrong way only increases the learning curve when it comes to doing things the right way. A check constraint is definitely the best way of doing it. However, if you must do it with a trigger this is the way to go:
CREATE OR REPLACE TRIGGER play_ins_con BEFORE INSERT ON player
FOR EACH ROW
BEGIN
IF months_between(:NEW.contract_end, :NEW.contract_start) <> :NEW.contract_length
THEN
RAISE_APPLICATION_ERROR(-30001, 'Contract length incorrect');
END IF;
END play_ins_con;
/Incidentally, as CONTRACT_LENGTH is wholly derivable from the other columns your table structure is obviously insufficiently normalised.
Also, note that only errors between -20999 and -20000 are reserved for our use. Any other number may be used by Oracle for its own purposes.
Cheers, APC -
ORA-01403: no data found error hile inserting into a table
Hi,
I am populating a PL/SQL table(Array) with the data. From that array inserting into a Actual table. Before inserting am checking array count. Array count is greater than 0. But I am getting "ORA-01403: no data found" exception. I am not getting why this error is displaying.
Please someone help me. Below is the code.
CREATE OR REPLACE PROCEDURE XXDL_TEST_INSERT
IS
BEGIN
IF t_array.count> 0 THEN
FND_FILE.PUT_LINE (FND_FILE.LOG, t_array.count);
FOR i IN t_array.FIRST..t_array.LAST
LOOP
INSERT INTO XXDL_TEST
VALUES(t_array(i).name )
END LOOP;
END IF;
EXCEPTION
WHEN OTHERS THEN
FND_FILE.PUT_LINE (FND_FILE.LOG,SQLERRM);
END;Thanks
AlakaIt looks like your Array is sparsely populated:
SQL> DECLARE
2 TYPE l_tab_type IS TABLE OF VARCHAR2(10)
3 INDEX BY BINARY_INTEGER;
4 l_tab l_tab_type;
5 BEGIN
6 l_tab(1) := 'A';
7 l_tab(2) := 'B';
8 l_tab(3) := 'C';
9 FOR i IN l_tab.FIRST .. l_tab.LAST LOOP
10 dbms_output.put_line(l_tab(i));
11 END LOOP;
12 END;
13 /
A
B
C
PL/SQL procedure successfully completed.
SQL>
SQL> DECLARE
2 TYPE l_tab_type IS TABLE OF VARCHAR2(10)
3 INDEX BY BINARY_INTEGER;
4 l_tab l_tab_type;
5 BEGIN
6 l_tab(1) := 'A';
7 l_tab(3) := 'B';
8 l_tab(4) := 'C';
9 FOR i IN l_tab.FIRST .. l_tab.LAST LOOP
10 dbms_output.put_line(l_tab(i));
11 END LOOP;
12 END;
13 /
A
DECLARE
ERROR at line 1:
ORA-01403: no data found
ORA-06512: at line 10Edited by: JS1 on Apr 11, 2009 8:59 AM
You should also be using the FORALL syntax with INDICES OF. Check out The Docs -
ORA-01403: no data found - refresh after insert on view
Hi all,
I have problems with refresh after insert on view and i override this method on my xxDefImpl.java
public boolean isUseReturningClause() {
return false;
Anyway what it does is to substitute the RETURNIN INTO to
SELECT ID INTO ? FROM MY_VIEW WHERE ID=?; END;".
And this gives me the error
ORA-01403: no data found ORA-06512: at line 1
Because i'm tryint to insert on my view with ID = -1
And then the view and the my triggers make it happen to became a real ID.
The thing is that i need to refresh my ID after insert and it runs this select with -1 and it finds no data of course because the trigger on the view and on my tables transformed it in a real ID .
DO u know what's missing?See section 26.5 Basing an Entity Object on a Join View or Remote DBLink in the ADF Developer's Guide for Forms/4GL Developers for the additional tip I believe you're missing about marking a unique attribute as well.
You can find the guide on the ADF Learning Center on OTN here:
http://www.oracle.com/technology/products/adf/learnadf.html -
I am getting ORA-01403: no data found error while calling a stored procedur
Hi, I have a stored procedure. When I execute it from Toad it is successfull.
But when I call that from my java function it gives me ORA-01403: no data found error -
My code is like this -
SELECT COUNT(*) INTO L_N_CNT FROM TLSI_SI_MAST WHERE UPPER(CUST_CD) =UPPER(R_V_CUST_CD) AND
UPPER(ACCT_CD)=UPPER(R_V_ACCT_CD) AND UPPER(CNSGE_CD)=UPPER(R_V_CNSGE_CD) AND
UPPER(FINALDEST_CD)=UPPER(R_V_FINALDEST_CD) AND UPPER(TPT_TYPE)=UPPER(R_V_TPT_TYPE);
IF L_N_CNT >0 THEN
DBMS_OUTPUT.PUT_LINE('ERROR -DUPlicate SI-1');
SP_SEL_ERR_MSG(5,R_V_ERROR_MSG);
RETURN;
ELSE
DBMS_OUTPUT.PUT_LINE('BEFORE-INSERT');
INSERT INTO TLSI_SI_MAST
( CUST_CD, ACCT_CD, CNSGE_CD, FINALDEST_CD, TPT_TYPE,
ACCT_NM, CUST_NM,CNSGE_NM, CNSGE_ADDR1, CNSGE_ADDR2,CNSGE_ADDR3,
CNSGE_ADDR4, CNSGE_ATTN, EFFECTIVE_DT, MAINT_DT,
POD_CD, DELVY_PL_CD, TRANSSHIP,PARTSHIPMT, FREIGHT,
PREPAID_BY, COLLECT_BY, BL_REMARK1, BL_REMARK2,
MCC_IND, NOMINATION, NOTIFY_P1_NM,NOTIFY_P1_ATTN , NOTIFY_P1_ADDR1,
NOTIFY_P1_ADDR2, NOTIFY_P1_ADDR3, NOTIFY_P1_ADDR4,NOTIFY_P2_NM,NOTIFY_P2_ATTN ,
NOTIFY_P2_ADDR1,NOTIFY_P2_ADDR2, NOTIFY_P2_ADDR3, NOTIFY_P2_ADDR4,
NOTIFY_P3_NM,NOTIFY_P3_ATTN , NOTIFY_P3_ADDR1,NOTIFY_P3_ADDR2, NOTIFY_P3_ADDR3,
NOTIFY_P3_ADDR4,CREATION_DT, ACCT_ATTN, SCC_IND, CREAT_BY, MAINT_BY
VALUES( R_V_CUST_CD,R_V_ACCT_CD,R_V_CNSGE_CD,R_V_FINALDEST_CD,R_V_TPT_TYPE,
R_V_ACCT_NM,R_V_CUST_NM ,R_V_CNSGE_NM, R_V_CNSGE_ADDR1,R_V_CNSGE_ADDR2, R_V_CNSGE_ADDR3,
R_V_CNSGE_ADDR4,R_V_CNSGE_ATTN, R_V_EFFECTIVE_DT ,SYSDATE, R_V_POD_CD,R_V_DELVY_PL_CD,R_V_TRANSSHIP ,R_V_PARTSHIPMT , R_V_FREIGHT,
R_V_PREPAID_BY ,R_V_COLLECT_BY ,R_V_BL_REMARK1 ,R_V_BL_REMARK2,R_V_MCC_IND,
R_V_NOMINATION,R_V_NOTIFY_P1_NM, R_V_NOTIFY_P1_ATTN, R_V_NOTIFY_P1_ADD1, R_V_NOTIFY_P1_ADD2,
R_V_NOTIFY_P1_ADD3, R_V_NOTIFY_P1_ADD4, R_V_NOTIFY_P2_NM, R_V_NOTIFY_P2_ATTN, R_V_NOTIFY_P2_ADD1,
R_V_NOTIFY_P2_ADD2, R_V_NOTIFY_P2_ADD3, R_V_NOTIFY_P2_ADD4, R_V_NOTIFY_P3_NM, R_V_NOTIFY_P3_ATTN,
R_V_NOTIFY_P3_ADD1, R_V_NOTIFY_P3_ADD2, R_V_NOTIFY_P3_ADD3, R_V_NOTIFY_P3_ADD4,
SYSDATE,R_V_ACCT_ATTN,R_V_SCC_IND,R_V_USER_ID,R_V_USER_ID
DBMS_OUTPUT.PUT_LINE(' SI - REC -INSERTED');
END IF;Hi,
I think there is a part of the stored procedure you did not displayed in your post. I think your issue is probably due to a parsed value from java. For example when calling a procedure from java and the data type from java is different than expected by the procedure the ORA-01403 could be encountered. Can you please show the exact construction of the call of the procedure from within java and also how the procedure possible is provided with an input parameter.
Regards, Gerwin -
NEED HELP IN CONFLICT HANDLER ERROR ORA-01403: no data found
Hi All,
I am using Oracle Streams to replicate the data...
I need to update the records on the destination with some particular condition like if USER_COUNTRY = 'XXX' then the data need to be updated in the destination side else skip ...
I wrote the procedure ..below .. the data is not replicating and found the below error from dba_apply_error..
ORA-01403: no data found
ORA-06512: at "SYS.LCR$_ROW_RECORD", line 419
Table called history_row_lcrs is created in the strmadmin to store the lcr values...
CREATE OR REPLACE PROCEDURE proc_test(in_any sys.anydata)IS
lcr sys.lcr$_row_record;
rc pls_integer;
v_type varchar2(20);
col_1 sys.anydata;
lcr_usercountry varchar2(20);
TRANS varchar2(20);
skip_routine Exception;
BEGIN
rc:=in_any.GetObject(lcr);
v_type:=lcr.get_command_type();
col_1:=lcr.get_value('NEW','USER_COUNTRY');
rc:=col_1.GetVarchar2(lcr_usercountry);
for x in ( select user_country from TEST.TESTREP1
where USER_COUNTRY=lcr_usercountry)
Loop
IF (x.USER_COUNTRY = 'XXX')
THEN
insert into strmadmin.history_row_lcrs VALUES (SYSDATE, lcr.GET_SOURCE_DATABASE_NAME(), lcr.GET_COMMAND_TYPE(),
lcr.GET_OBJECT_OWNER(), lcr.GET_OBJECT_NAME(), lcr.GET_TAG(), lcr.GET_TRANSACTION_ID(), lcr.GET_SCN(),
lcr.GET_COMMIT_SCN,lcr.GET_VALUES('old'), lcr.GET_VALUES('new', 'n'));
lcr.EXECUTE(true);
ELSE
Raise Skip_routine;
END IF;
END Loop;
Exception
when skip_routine Then
null;
END;
BEGIN
DBMS_APPLY_ADM.SET_DML_HANDLER(
object_name => 'TEST.TESTREP1',
object_type => 'TABLE',
operation_name => 'UPDATE',
error_handler => false,
user_procedure => 'STRMADMIN.PROC_TEST',
apply_database_link => NULL,
apply_name => NULL);
END;
Please try to help me if am doing something wrong...because I need to update only one colums am using DML_HANDLER instead of SET_UPDATE_CONFLICT_HANDLER...
Any other inputs are also appreciated...
Thanks In Advance and appreciate for the quick reply...I fired the query, am not getting any output from dbms_output.put_line('..|USER_COUNTRY..');
Is that no data is reading or may be any reason else..
in this table store_id is the primary key ..
SQL> set serveroutput on
SQL> CREATE OR REPLACE PROCEDURE test(in_any sys.anydata) IS
2 lcr sys.lcr$_row_record;
3 rc pls_integer;
4 v_type varchar2(20);
5 col_1 sys.anydata;
6 col_2 sys.anydata;
7 lcr_usercountry varchar2(20);
8 lcr_storeid number;
9 TRANS varchar2(20);
10 store_id number;
11 USER_COUNTRY varchar2(20);
12
13 BEGIN
14 rc:=in_any.GetObject(lcr);
15 v_type:=lcr.get_command_type();
16 col_1:=lcr.get_value('NEW','USER_COUNTRY');
17 rc:=col_1.GetVarchar2(lcr_usercountry);
18 col_2:=lcr.get_value('NEW','STORE_ID');
19 rc:=col_2.getnumber(lcr_storeid);
20 select user_country into user_country from dev03.testrep1 where user_country=lcr_usercountry and store_id=lcr_storeid;
21 dbms_output.put_line('---------||USER_COUNTRY ||-----------');
22 END;
23 /
Procedure created.
Thanks for your help .... -
ORA-01403: no data found when calling a web service from HTMLDB
I am working through Section 6 How to Implement a Web Service of the HTML DB 2 Day Developer tutorial. I can get the first example to work but not the second one. I am able to add the web reference and create the form and report. However, when I run the page and click submit, I get ORA-01403: no data found.
When I test the service, this is what shows in the Message Request:
<?xml version='1.0' encoding='UTF-8'?><SOAP-ENV:Envelope
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:xsi="http://www.w3.org/1999/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/1999/XMLSchema">
<SOAP-ENV:Header><namesp1:Header xmlns:namesp1="http://www.xignite.com/services/"><namesp1:Username xsi:type="xsd:string"></namesp1:Username><namesp1:Password xsi:type="xsd:string"></namesp1:Password><namesp1:Tracer xsi:type="xsd:string"></namesp1:Tracer></namesp1:Header></SOAP-ENV:Header><SOAP-ENV:Body><namesp1:ListFuturesByExchange xmlns:namesp1="http://www.xignite.com/services/"><namesp1:Exchange xsi:type="xsd:string">NYMEX</namesp1:Exchange></namesp1:ListFuturesByExchange></SOAP-ENV:Body></SOAP-ENV:Envelope>
Nothing shows in the Message Response.
I have also tried to call a simple web service that I created in .NET. It exhibits the same behavior. I am able to add the reference and create the form. But when I click the submit button, I get ORA-01403: no data found.
Windows 2000
HTMLDB 2.0.0.00.49
Oracle9i 9.2.0.6.0
Any help will be greatly appreciated.I'm having a similar problem!, Although, distressing as it is to observe the lack of response this thread has had for 9 months, I'm still seeking help here!
I created a web service reference according to the following WSDL : "http://OgAppExpress:[email protected]:5555/invoke/OgAdminUtils.pub:WSDL_HLR" (operation name="getSubscriberInfoByMSISDN") and a form on that web service, all of which went very nicely. But! When I ran the form, inserted the value ("3546933599") into the parameter and pressed submit.... => "ORA-01403: no data found"
The debug action displays very limited information and sheds no light on the problem :( Multiple attempts, on recreating the project from scratch, have resulted in the same utter failure! Needless to say, this nulls the affect of my Prozac proscription....
Is there anybody out there who can help me and defend APEX's reputation? -
ORA-01403: no data found
I am trying to make Form on a Table with Report.
And my Form is ok, I can successfully insert data. But the problem is report. When I click
on EDIT button, when I want to change inserted data, I get error message:
ORA-01403: no data found
Error Unable to fetch row.
Thanks!!!Hi,
I am getting the following error ORA-01403 no data found. I have a hidden item called Temporary item which i created as i have a report that appears with additional information when clicked on show_detail. I created this item by looking at this:
http://htmldb.oracle.com/pls/otn/f?p=11933:13:2667331074727537::NO:RP::
At the top of page 24 i have a text box and a search button Go that presents the report that matches the number that the user will type in the text box. I have created a branch to the same page. In my Report region i have code that will select the information from the database where id = :P24_SEARCH_ID
P24_SEARCH_ID is the text box.
I tried inserting in the branch> set TEMPORARY_ITEM to values P24_SEARCH_ID and then insert id=:TEMPORARY_ITEM in the region , but this would not work.
Sometimes the Go button works but when i log out and log back into apex and try running it, i get the error
Any suggestions as to how i can make it work always?
Monica -
ORA-01403: no data found in alert.log
Dear All,
I am getting ORA-01403: no data found in alert.log.Could you pls help me out what could be reasons behind it..Due to this i m getting loads of alerts.Pls suggest.
ThanksORA-01403 No Data Found
Typically, an ORA-01403 error occurs when an apply process tries to update an existing row and the OLD_VALUES in the row LCR do not match the current values at the destination database.
Typically, one of the following conditions causes this error:
Supplemental logging is not specified for columns that require supplemental logging at the source database. In this case, LCRs from the source database might not contain values for key columns. You can use a DML handler to modify the LCR so that it contains the necessary supplemental data. See "Using a DML Handler to Correct Error Transactions". Also, specify the necessary supplemental logging at the source database to prevent future errors.
There is a problem with the primary key in the table for which an LCR is applying a change. In this case, make sure the primary key is enabled by querying the DBA_CONSTRAINTS data dictionary view. If no primary key exists for the table, or if the target table has a different primary key than the source table, then specify substitute key columns using the SET_KEY_COLUMNS procedure in the DBMS_APPLY_ADM package. You also might encounter error ORA-23416 if a table being applied does not have a primary key. After you make these changes, you can reexecute the error transaction.
The transaction being applied depends on another transaction which has not yet executed. For example, if a transaction tries to update an employee with an employee_id of 300, but the row for this employee has not yet been inserted into the employees table, then the update fails. In this case, execute the transaction on which the error transaction depends. Then, reexecute the error transaction.
There is a data mismatch between a row LCR and the table for which the LCR is applying a change. Make sure row data in the table at the destination database matches the row data in the LCR. When you are checking for differences in the data, if there are any DATE columns in the shared table, then make sure your query shows the hours, minutes, and seconds. If there is a mismatch, then you can use a DML handler to modify an LCR so that it matches the table. See "Using a DML Handler to Correct Error Transactions".
Alternatively, you can update the current values in the row so that the row LCR can be applied successfully. If changes to the row are captured by a capture process at the destination database, then you probably do not want to replicate this manual change to destination databases. In this case, complete the following steps:
Set a tag in the session that corrects the row. Make sure you set the tag to a value that prevents the manual change from being replicated. For example, the tag can prevent the change from being captured by a capture process.
EXEC DBMS_STREAMS.SET_TAG(tag => HEXTORAW('17'));
In some environments, you might need to set the tag to a different value.
Update the row in the table so that the data matches the old values in the LCR.
Reexecute the error or reexecute all errors. To reexecute an error, run the EXECUTE_ERROR procedure in the DBMS_APPLY_ADM package, and specify the transaction identifier for the transaction that caused the error. For example:
EXEC DBMS_APPLY_ADM.EXECUTE_ERROR(local_transaction_id => '5.4.312');
Or, execute all errors for the apply process by running the EXECUTE_ALL_ERRORS procedure:
EXEC DBMS_APPLY_ADM.EXECUTE_ALL_ERRORS(apply_name => 'APPLY');
If you are going to make other changes in the current session that you want to replicate destination databases, then reset the tag for the session to an appropriate value, as in the following example:
EXEC DBMS_STREAMS.SET_TAG(tag => NULL);
In some environments, you might need to set the tag to a value other than NULL. -
ORA-01403: no data found (WWV-16016) error
I have a very simple form with two fields. This form is opened in the update mode through a report which pass a parameter to the form. When I press 'Delete' button to delet the record, I get this error message:
Error: An unexpected error occurred: ORA-01403: no data found (WWV-16016)
But the record is actually deleted by this action.
Does anyone know why and how to fix it?
Thanks!I have the same problem when i call form based on procedure in insert mode. However, i can insert one record normally, when i try to insert another one, this error appears.
This behavior is really extremly annoying and i would really like to know why this error apprears and how to get rid of it.
Kind regards,
Damjan
<BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by sz():
I have a very simple form with two fields. This form is opened in the update mode through a report which pass a parameter to the form. When I press 'Delete' button to delet the record, I get this error message:
Error: An unexpected error occurred: ORA-01403: no data found (WWV-16016)
But the record is actually deleted by this action.
Does anyone know why and how to fix it?
Thanks!<HR></BLOCKQUOTE>
null -
Ora-01403 no data found cursor error - Please help.
DECLARE
name1 talent.candidate_name%TYPE; -- Declare variables
name2 long; -- Declare variables
emp_id talent_id.emplid%TYPE;
NO_DATA_FOUND EXCEPTION;
CURSOR c1 IS
select candidate_name,(''''||trim(upper(candidate_name))||'''') as tst from talent ;
BEGIN
OPEN c1;
LOOP
FETCH c1 INTO name1, name2;
EXIT WHEN c1%NOTFOUND; -- TRUE when FETCH finds no more rows
select distinct emplid
INTO emp_id
from names a
where a.name_type = 'PRI'
and upper(a.last_name)||', '||upper(a.first_name) = name2;
INSERT INTO talent_id VALUES (emp_id, name1);
END LOOP;
CLOSE c1;
COMMIT;
Question: Above queries prompt me error msg ora-01403 no data found for emplid. I try but fail to solve it. Please help me. Thank you
Edited by: user12051088 on Mar 4, 2010 1:38 AM
Edited by: user12051088 on Mar 4, 2010 1:40 AMYes, this is very helpful :-)
My testing to insert table where emplid is null but still having error ora-01403 no data found when i remove on dbms_output.put_line as shown below:
Anyway, if i dint remove the dbms_output.put_line. It is working to insert emp_id is not null. How do I include record which emp_id is null? Thank you.
begin
select distinct emplid
INTO emp_id
from gdw_names a
where a.name_type = 'PRI'
and upper(a.last_name)||', '||upper(a.first_name) = name1;
IF emp_id is null THEN
RAISE no_data_found;
else
INSERT INTO gdw_talent_id VALUES (emp_id, name1);
end if;
exception
when no_data_found then
INSERT INTO gdw_talent_id VALUES (null, name1);
--when too_many_rows then
-- dbms_output.put_line('too many rows for ' || name1);
-- when others then
-- dbms_output.put_line('Unknown error for ' || name1);
end;
Edited by: user12051088 on Mar 4, 2010 9:11 PM -
Error ORA-01403: no data found is not raised using jdbc
Hy there I have a problem receiving exceptions from oracle jdbc driver.
I have the following exception stack if i call insert on a view
using an instead of trigger.
ORA-01403: no data found
ORA-04088: error during execution of trigger
'MYUSER.MY_VIEW_INSERT'
if I do the insert by sql worksheet.
If I do same insert using the following driver
dbDriver = new intersolv.jdbc.sequelink.SequeLinkDriver();
I will receive this exception:
java.sql.SQLException: [INTERSOLV][SequeLink JDBC Driver][ORACLE]ORA-01403: Keine Daten gefunden
Now if I do same thing using oracle driver:
dbDriver = new oracle.jdbc.driver.OracleDriver();
there will no exception be raised!
here is my code:
public class myFrame extends Frame
public static void main( String[] args )
Frame myFrame = new Frame();
DbPflege dbPanel = new DbPflege();
Driver dbDriver = null;
String connectString = null;
try
if( args.length != 0 )
System.out.println( "main: use sequelink!" );
connectString = "jdbc:sequelink://myServer:4003/[Oracle]";
dbDriver = new intersolv.jdbc.sequelink.SequeLinkDriver();
else
System.out.println( "main: use oracle!" );
connectString = "jdbc:oracle:thin:@myServer:1521:idb";
dbDriver = new oracle.jdbc.driver.OracleDriver();
DriverManager.registerDriver( dbDriver );
dbPanel.con = DriverManager.getConnection(connectString, "user", "pwd" );
catch( Exception ex )
System.out.println( "main: ERROR: " + ex );
ex.printStackTrace();
void jBtnExecute_actionPerformed(java.awt.event.ActionEvent event)
Statement stmt = null;
int updateCount = -1;
int colCount = -1;
ResultSet rs = null;
ResultSetMetaData rsMeta = null;
try
stmt = con.createStatement();
stmt.execute( textAreaInput.getText() );
catch( Exception ex )
textAreaOutput.append( ex.toString() );
thanks for your help!!!!Hi,
You should run you query in sql workshop with the expected values (which are set after user clicks Save or Apply changes button) for P10_CR_BOM_CODE and P10_CR_ID.
Also, please have an exception block in the process to catch any exception and make an appropriate Insert into some user defined error-log table. It would be better to log the P10_CR_BOM_CODE and P10_CR_ID values in case of exception.
These might help you to figure out the cause of exception.
Regards,
Mangal -
Error 'ORA-01403 no data found', if a procedure called through $Universe
Hello,
we use at our customer the scheduling software $Universe. The problem follows is happend at calling PL/SQL-procedures within SQL*Plus:
Within the calling procedur another subprogram will be called. This program crashed on select of currval with the error 'ORA-01403 no data found'. This error happens only, if the procedure called through $Universe. If the procedure called directly from SQL*Plus or about a unix shell-script, no error happens.
About the command "select saddr,sid,serial# from sys.V_$SESSION where
username ='xxx';" we select the Session_ID's. These are identically before and after call of the procedure!
Do you have an idea, how the problem can be?
Next information about OS, releases, settings of Oracle-Session-Parameters, and the crashing procedure:
SQL*Plus: Release 8.1.6.0.0 - Production on Fri Mar 15 13:25:05 2002
(c) Copyright 1999 Oracle Corporation. All rights reserved.
Connected to:
Oracle8i Enterprise Edition Release 8.1.6.0.0 - Production
With the Partitioning option
JServer Release 8.1.6.0.0 - Production
OS: HP-UX11
ORACLE-Server NLS-parameters on HP-UX:
NLS_LANGUAGE AMERICAN
NLS_TERRITORY AMERICA
NLS_CURRENCY $
NLS_ISO_CURRENCY AMERICA
NLS_NUMERIC_CHARACTERS .,
NLS_CALENDAR GREGORIAN
NLS_DATE_FORMAT DD-MON-RR
NLS_DATE_LANGUAGE AMERICAN
NLS_CHARACTERSET WE8DEC
NLS_SORT BINARY
NLS_TIME_FORMAT HH.MI.SSXFF AM
NLS_TIMESTAMP_FORMAT DD-MON-RR HH.MI.SSXFF AM
NLS_TIME_TZ_FORMAT HH.MI.SSXFF AM TZH:TZM
NLS_TIMESTAMP_TZ_FORMAT DD-MON-RR HH.MI.SSXFF AM TZH:T
NLS_DUAL_CURRENCY $
NLS_NCHAR_CHARACTERSET WE8DEC
NLS_COMP BINARY
Windows-desktop NLS-parameters:
ALTER SESSION set NLS_LANGUAGE = 'GERMAN';
ALTER SESSION set NLS_TERRITORY = 'GERMANY';
ALTER SESSION set NLS_ISO_CURRENCY = 'GERMANY';
ALTER SESSION set NLS_NUMERIC_CHARACTERS = ',.';
ALTER SESSION set NLS_CALENDAR = 'GREGORIAN';
ALTER SESSION set NLS_DATE_FORMAT = 'DD/MM/YY';
ALTER SESSION set NLS_DATE_LANGUAGE = 'GERMAN';
ALTER SESSION set NLS_SORT = 'GERMAN';
ALTER SESSION set NLS_TIME_FORMAT = 'HH24:MI:SSXFF';
ALTER SESSION set NLS_TIMESTAMP_FORMAT = 'DD.MM.RR HH24:MI:SSXFF';
ALTER SESSION set NLS_TIME_TZ_FORMAT = 'HH24:MI:SSXFF TZH:TZM';
ALTER SESSION set NLS_TIMESTAMP_TZ_FORMAT = 'DD.MM.RR HH24:MI:SSXFF
TZH:TZM';
ALTER SESSION set NLS_DUAL_CURRENCY = '?';
ALTER SESSION set NLS_COMP = 'BINARY';
PROCEDURE PROC_NEW_ID (p_value IN NUMBER,
p_field IN VARCHAR2,
p_table IN VARCHAR2,
p_currval OUT NUMBER)
IS
v_stmt VARCHAR2(200);
v_currval NUMBER;
BEGIN
-- Bildung des SQL-Statements.
v_stmt := 'INSERT INTO '||p_table|| '('|| p_field || ') VALUES
('||p_value||')';
-- Ausfuehren des SQL-Statements.
EXECUTE IMMEDIATE v_stmt;
COMMIT;
-- Bildung des SQL-Statements.
v_stmt := 'SELECT SEQ_'|| p_table || '.CURRVAL FROM DUAL';
-- Ausfuehren des SQL-Statements.
EXECUTE IMMEDIATE v_stmt INTO v_currval;
-- Wertrueckgabe
p_currval := NVL(v_currval,0);
EXCEPTION
WHEN OTHERS THEN
pkg_mira_protokoll.proc_write_error_fwd
(pkg_mira_consts.act_error,
SQLCODE,
SQLERRM(SQLCODE),
'PROC_NEW_ID');
p_currval := 0;
RAISE;
END;
Thanks for your request!
Best regards
Esser Office Consulting KG
J|rgen EsserThis forum is for posting feedback about the OTN site.
The best place for your question is probably a Portal forum.
There is a list of Portal forums here:
http://forums.oracle.com/forums/index.jsp?cat=13 -
Update conflict resoltion ORA-01403: no data found
I have set up multimaster replication environment with two database and I have implemented Update conflict resolution on a table using DISCARD method(Oracle provided) as below.
Some how it is not able to resolve the conflict and I am getting erro ORA-01403: no data found.
On MDS(M1) I run the follwing SQL
update menu_code
set ipp_uid = 20
where id = 4;
commit;
on master(M2) database in table menu_code row with ID=4 doesn't exsit.
When I apply deffred transaction that gnerated by above SQL
I get ORA-01403: no data found and ofcourse trnsaction doesn't apply to db and goes to deferror. Since I am using DISCARD method
it should be resolved and not to gnerate error message.
Here is detail info.
Table name: menu_code
--creating column group
BEGIN
DBMS_REPCAT.MAKE_COLUMN_GROUP (
sname => 'SYNAPSE',
oname => 'MENU_CODE',
column_group => 'MENU_CODE_CG1',
list_of_column_names => 'id,ipp_uid');
END;
-- adding update conflict resolution
BEGIN
DBMS_REPCAT.ADD_UPDATE_RESOLUTION (
sname => 'SYNAPSE',
oname => 'MENU_CODE',
column_group => 'MENU_CODE_CG1',
sequence_no => 1,
method => 'DISCARD',
parameter_column_name => 'id,ipp_uid');
END;
--regenerating support for the table.
BEGIN
DBMS_REPCAT.GENERATE_REPLICATION_SUPPORT (
sname => 'SYNAPSE',
oname => 'MENU_CODE',
type => 'TABLE',
min_communication => TRUE);
END;
Thanks.
PravinYou are absolutely right. Now we decided not to write any conflict resolution routine at all.
Non MDS database is read-only till fail over. After fail over non MDS (other master) will allow insert/update operation.
To fail back to MDS we will write our procedure/function, out side of Oracle conflict resolution( both database will be in Read only mode during synchronizing).
We will delete all deferred transaction/error form the queue and once data transfer is complete, again MDS becomes primary database to use.
Oracle conflict resolutions are to complicated and has lots of overhead and maintenance.
Thanks.
Pravin -
ORA-01403 :no data found in apex
dear all
Please, not to view this thread as the contents are same posted in another thread with a different subject.
i have a form with 6 regions.
in one of the region i place a button save.
i have a conditional process to insert the data in the table
after entering the data into the respective fields when i click the save button
it is giving this error.
ORA-01403: no data found
Error UNABLE TO INSERT
OK
what is this error why it is comming?
how to solve it? if anyone gives solution it would be a bright day for me.
Message was edited by:
srikaviORA-01403 occurs when an SQL SELECT statement written inside a PL/SQL proceedure/function etc is expected to return a row (or more) but doesn't.
So, your code to save might read along the lines of:
declare
bar number;
begin
select foo into bar from foobar where id=1;
insert into ... where id=bar;
end;
Now, if the SELECT statement didn't return a row (ie, in the example above there are no records with an id of 1) then you will get an ORA-01403 error.
Look at your proceedure for saving and run any select statements seperately in a SQL editor and check that all return one or more rows.
Maybe you are looking for
-
Issue with Bex report - key Figures not populating correctly.
Hi Experts, I am facing an issue with a Bex report. There are three key figures of data type DATE having "Dec - Counter or amount field with comma and sign" datatype. After executing the query, in the report, for some sales documents the key figure f
-
Is there a way to edit in Imovie without the format being DV?
So I have to give a small project to someone just to decide what parts they want in and out. I was going to use Imovie because it is easy for them to use. Problem is I don't want the file size to be too big. I don't care about quality, this is just f
-
Hi.. I have to develop a web application in my last semester of Bachelor of Engineering using technologies like Servlets, JSP, AJAX, JavaScript, struts, portlets .. Please give me some ideas on which domain I can develop a good project. The project s
-
Duplicate photos now in Photo from iPhoto
Hi, I uploaded photos from my Mac to my iPad(3) using Photosync. The album appears nicely under Albums in the Photo app along with the pics in Camera Roll. I then make my edits in iPhoto (latest relase). So then, in iPhoto, i have the pics with the l
-
How to I get library songs upgraded from 128k to 256k
How to I get library songs upgraded from 128k to 256k. That is the reason I signed up for match in the first place.