On the first episode, we installed and configured Data Entry 123, on the second opus, we created a selector and two entry forms. That’s a very good start, it is time to look at **calculations**, we are going to copy data from one cube to the other when a form is opened or data is saved.

## Adding Calculations to a Data Entry 123 solution

We wrote a simple calculation that takes the numbers from the Fiscal Year Cube and shifts periods to match the Calendar Year periods. There are plenty of Time functions within OneStream,that can be a very good subject for a later blog post and we used a Data Buffer to copy data from one slice of the cube to the other, that can be another very good blog post.

Let’s get started and open the **Calculation Builder** from Data Entry 123:

Again, the same logic is applied with Calculation Group and Calculations: Groups, lists, all modular…

In our case, all calculations are executed from the FY forms: we need to execute the rule FY2CY when we save data and execute CY2FY when we open the form. For this, we check the appropriate boxes: FY2CY with ‘Run On Save’ and CY2FY with ‘Run On Open’:

**Good to know**: when you check ‘Show in List’ box, the calculation will show in the form. You can also personalize the order to which the calculations will show in the drop down.

## Tweaking Calculations POVs

What I like the most with executing calculations is that **you can tweak the POV for your rule specifically**:

The form pulls data from the ‘Sample FY’ cube, the cube POV can be whatever you want, the forms will take this value because it is hardcoded in the Cube View. Now, what’s great is that with Data Entry 123, I can run the calculation from the ‘Sample FY’ cube for the rule ‘CY2FY’ and from the ‘Sample’ cube for the ‘CY2FY’ rule. The OneStream calculation engine will take the POV setup in the Calculation builder and it gives a lot of freedom to developers.

Same, you have **flexibility** for the Time dimension:

Note that the rule will use the POV value of the Time and add some tweaks to it for all Calc Time Types except the last one ‘Member Filter’ where you can use a value from a selector. I try to avoid ‘Member filter’ and prefer to use what is on your POV because I prefer to manage Time exclusively from the POV for more consistency but I am sure there are use cases where ‘Member Filter’ comes very handy.

## Attaching Calculations to a Form

Now, all we have to do is to attach the rule to the form:

And verify results:

And we are almost done! We created a form with calculations and all data is in sync now! Last, we need to integrate our beautiful Data Entry 123 forms in the OneStream Workflow to create a killer application.

## One Reply to “DataEntry 123 Part 3 – Compute more with Calculations”