EF6 oracle stored procedure not executing properly

Viewed 14

I have oracle procedure driving me crazy, it sometimes execute just fine and sometimes is not inserting any record to the other table. Procedure is to select from a view and insert to a table like :

CREATE OR REPLACE PROCEDURE INSERT_VIEW_TABLE_TEST(YER NUMBER, MNT NUMBER) IS

BEGIN
        
            DELETE T1;-- WHERE YYYY = YER AND MM = MNT;
            

            INSERT INTO T1
            SELECT * FROM v1 WHERE YYYY = YER AND MM = MNT;        
        
                        


 COMMIT;
END;
/

This view has a big LEFT OUTER JOIN select statement from many tables.

And in .net code is : return db.INSERT_VIEW_TABLE_TEST(yr, mnth);

Please note that deletion in the first line is executed successfully each time but insert isn't. Insert executed for a couple of hours then I don't know what happend!

Where is my mistake?

0 Answers
Related