oracle - --PL/SQL--cursor returns only the first line, then the loop is over -
i have table named xxald_int_in_vehicle_item
, in there 11 lines.
i define cursor:
cursor line_veh select * xxald_int_in_vehicle_item update ;
i take lines 1 one, , handle it, update field of line(error_code).
open line_veh; loop fetch line_veh line; exit when line_veh%notfound; if line.ald_prosys_or_att_n null v_error := v_error ||'ald_prod_system|'; end if; ... update xxald_int_in_vehicle_item set error_code= v_error current of line_veh; commit; end loop; close line_veh;
the problem is, why after traitement of first line, loop finishes? other 10 lines not fetched.
can move commit outside loop? think conflicts update cursor. (for update living in 1 transaction.)
Comments
Post a Comment