Dear Mehrej,
For those cases specifically when this issue arises you can also check in Debugger Mode your Internal Table in which you're updating the values, check from where it's getting the pricing date in ITAB. Also check up with the loops logic as if it's okay because i'm sure that there's some issue in it. Thanks, try to give a shot and i'm sure this will gonna work out.