Hi,
Also when you are looping same table then u may exclude your first read statement and
add your condition in loop itself
loop at lt_SWPSTEPLOG into ls_SWPSTEPLOG where returntyp = 'RV'.
and use the values of ls_SWPSTEPLOG for comparing in second read statement for returntype = 'EV'