cancel
Showing results for 
Search instead for 
Did you mean: 

Benefits of using BRF plus for MM views creation in SAP

sanjana_lingras
Active Participant
0 Kudos

Hi Experts,

I am new to BRF+.

I need advise on usig BRFplus for MM view creations e.g. Accounting View.

For example there are few validations based on which view will be created for a material. These validation we can do based on the decision table.

This way we can avoid custom table configuration and custom code by using BRF+ , but are there any further advantages of using BRF+?

Like is it possible to handle view creation or error handling process to be done by BRF+  ?  Is BRF+ capable to display or send the errors back which occurred during creation or validation?

Thanks.

Regards,

Sanjana


Accepted Solutions (1)

Accepted Solutions (1)

anbusivam_s
Participant
0 Kudos

BRF+ is capable of sending back the errors during creation or validation. These error messages needs to be configured as result of a function. But displaying those errors at application layer(ui) should be done at the application side code.

sanjana_lingras
Active Participant
0 Kudos

Hi Anbusivam,

Thank you very much for the reply.

Can you please give one sample example on how to do it error handling in BRF+?

Thanks,

Sanjana


anbusivam_s
Participant
0 Kudos

Hi Sanjana,

For this you need to be familiar on how to use brf+ expressions for modeling business rules.

Basically you need to follow the below approach:

- Pass the values that needs to be validated into BRF+ as input parameters on a BRF+ function

- Define output parameter as a table object that returns text or the sysmessage id

- Later in your application coding you need to convert these text messages to appropriate error messages according to your application need or raise error messages based on sys message.

- Inside BRF+ you may use different expression type to validate the inputs. The common expression types are decision table, switch case, loop and rules itself.

For example if you want to validate discount range of a material. The input of brf+ function could be material, discount and output could be a text table or sys id table. In a decision table you can add two condition columns input, discount and a result column as a text message or sys message id. Add conditions for different material and different ranges and on certain erroneous range add the corresponding sysid or text in the result column.

This is just a hint. The modeling can vary according to your own need and vast set of combinations are possible to achieve the same result.

Hope this helps.

Regards,

Anbu

sanjana_lingras
Active Participant
0 Kudos

Hi Anbusivam,

Thanks for the quick reply. I would like to know about one more scenario for error handling.

If we have 2 validations in one ruleset for a single entry, is it possible to send error for one and success message for the other one?

i.e. Which validations were successful and failed one with messages...

Thanks.

Regards,

Sanjana

anbusivam_s
Participant
0 Kudos

Hi Sanjana,

Yes this is possible. That's why I have mentioned the result type as table so that you can populate any number of(success or failure) messages into it. But you may need to use two validating  expressions for it or the validating expression should be inside a loop that loops over a table of input values. So for each input row of data the expression should validate it and return a message which should get appended to the output table.

Regards,

Anbu

Answers (0)