Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

OPEN CURSOR FOR DELETE ROWS

543974Jul 7 2009 — edited Jul 7 2009
This transaction will work properly?
I know it work but I have feeling it may cause a problem
To open a cursor and delete the row I have selected.


CREATE OR REPLACE PROCEDURE PRC_MAIN_INTER IS
BEGIN
BEGIN

FOR A IN (SELECT B.HIST_ID
FROM MOBIDEO.MAIN_INTER B
WHERE B.STATUS = 9)
LOOP
BEGIN
DELETE MAIN_INTER C WHERE C.HIST_ID = A.HIST_ID;
COMMIT;
END LOOP;

END;
COMMIT;
END PRC_MAIN_INTERF;
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Aug 4 2009
Added on Jul 7 2009
5 comments
16,489 views