Author Topic: Stand Alone Calculation  (Read 133 times)

Offline jv_oz

  • Full Member
  • ***
  • Join Date: Apr 2015
  • Posts: 49
  • Forum Citizenship: +0/-0
    • Infocube
Stand Alone Calculation
« on: 03 Oct 2017 11:28:09 pm »
Hi everyone,

I have an odd one. I have a series of query subjects that build to provide a summary output of the sum of the time for production tasks to be completed vs the time available until production line needs to advance for each workstation on a production line. I have calculated the difference as C = B - A, where B is the number of minutes until the line advances (expressed as a decimal, so 73.5 represents 73 minutes and 30 seconds) and A is the sum of all the time required to complete all tasks at a workstation (also decimal). C then represents the difference to tell us if we need to throw more resource at a workstation to complete on time or not. All calculations need to be completed in FM because we are using CA 11 Dashboards, where you can't do calculation in the dashboard.

I have A and B calculating correctly in FM and have set C as Stand Alone Calculation and have then added C back into the query subject. I have 578 mins as A and 617 minutes against B. C should therefore calculate out to be 617-578=39 minutes, however C is calculating using the value in column A for the first record (2.5 minutes), rather than the sum of A.

For your info, the source is Oracle, I have defined the query subject as a "Summary Query", the Regular Aggregate for columns for A is set to "Sum" and B is set to "Average" (because the time until the line advances is  the same for all tasks and to add it up would be incorrect). The calculation C references these two columns.

Also it is interesting that if I place all columns from the query subject into a report and do the calculation of C = B - A there, it works perfectly.

Any advice you could give would be most appreciated!

Thanks

John
« Last Edit: 03 Oct 2017 11:57:16 pm by jv_oz »

 


       
Twittear