--!!!Update statement for initial filling of the table ZADR, only needed in POLAND to fulfill legal requirements (Nota Correction)!!!

DECLARE
 cursor c_Folios is
    select zinv_id, zinv_xadr_id from zinv where nvl(zinv_xadr_id, 0) > 0;

 rFolio c_Folios%rowtype;  
	
begin

 for rFolio in c_Folios loop
   StoreZadrData(rFolio.zinv_id, rFolio.zinv_xadr_id);
 end loop;

 commit;
end;	  
/
