Hi members,
I need to fetch the data in packages from the HANA view ( with help of external view), I have used the Cursor statement to do so.
In the Cursor fetch loop, i need to pass on that data to the asynchronous proxy method. I have to commit after sending the data to asynchronous proxy method. I tried it using the following approaches:
1. Using FM DB_COMMIT : the PI messages are still in the "message recorded,commit missing" status.
2. Using COMMIT WORK : The cursor is invalidated.
I can do the commit work after the Cursor loop, but this approach will keep all the messages in PI queue untill it gets the commit statement.
Please guide as how can this be resolved.
TRY.
OPEN CURSOR WITH HOLD c FOR SELECT DISTINCT .....
FROM ...
WHERE ...
DO.
FETCH NEXT CURSOR c INTO CORRESPONDING FIELDS OF TABLE lt_initiative PACKAGE SIZE gv_package_size.
:
:
--call to asynchronous PI message
" need to commit here
END DO.
close cursor c.
{ commit work here works fine}
Regards,
Nidhi