cancel
Showing results for 
Search instead for 
Did you mean: 

Endless loop in BRF+

Former Member
0 Kudos

Hi,

We are facing a strange problem in BRF+. In BRF+rule, they are looping over a table (say table1), carrying out a function and then appending the values to same table (table1). However bizzare it sounds , I am surprised that it works perfectly in BRF+ without any issue when we do simulation.


When I look at the ABAP code that is generated code and when BRF+ rule is tried to access via our program , PROCESS_PURE goes into an endless loop. Could you please let us know why it works in BRF+ simulation and how we could possibly work with the generated code?

Regards,

Sunil Kumar Choudhury

Accepted Solutions (0)

Answers (2)

Answers (2)

kakshat
Advisor
Advisor
0 Kudos

Were you able to establish via debugging that the endless loop is indeed because of the fact that the table being looped over is being appended at the same time? If not, I believe the best thing would be to debug and get to the root cause.

Sometimes, problems with passing the context values to BRF+ can also lead to unexpected results. For example, missing leading zeroes or the similar.

Jocelyn_Dart
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hmmmm .... Could it be that you are using interpretation mode when you Simulate?  Personally I avoid interpretation mode unless I really need it ... There are always small but critical differences between that & generated mode which is what will actually be used at runtime.

Suggest better design anyway to NOT append back to the same table while in the loop. That would be bad practice in many programming languages including ABAP & also bad in BRF+

- one option is to instead use different tables for input vs output

rgds

Jocelyn