Create a business rule in MDM 2012 that tests the Sum of attributes of an entity

455 Views Asked by At

I have created an entity on MDM 2012 and I like to create a business rule that tests if the SUM of 3 attributes is 100.

I didn't find a way on the Action Panel to use arithmetic operators or simply a SUM function.

1

There are 1 best solutions below

1
Naveen Kumar On

Not sure we can perform this directly or not but yes we can use custom user defined script to validate Sum of attribute values=100 or anything

try follow these steps -

Step#1 Creating a business rule with custom extensions in MDS; for that create a user define function in SQL to validate sum of 3 or 4 parameter is 100 or not

e.g. enter image description here

make sure function created under USR schema and RETURNS BIT

Step #2

Create Business Rule & select function created in step#1 as Operator

enter image description here

Make sure to click somewhere inside the parameter box. This will change the layout and allow you to assign an attribute to the parameter of the user defined script.

Step #3 What to do if condition met or not met

like enter image description here

Reference Business Rules Extension in MDS