I am trying to figure out how to use a flowfield to calculate percents of 'completed' records.
The table structure looks like the below
Table1 Header (key = No.)
-Table2 Lines (key =No., Line1)
--Table3 More Lines (key =No.,Line1,Line2)
"More Lines" has a field for status = status::completed
now Table2 "Lines" needs a field for percent complete. which would be calculated
"More Lines".SETRANGE on (No., Line1);
totalCount := "More Lines".COUNT
"More Lines".RESET;
"More Lines".SETRANGE on (No., Line1 and status::completed)
completedCount := "More Lines".COUNT;
percent := completedCount / totalCount;
Now this has to happen for the table header as well, but with the total records 'completed' on the Lines table. Is there any way to accomplish this with flowfields? I can't seem to do math at the table level on flowfields of that table. Any nudge in the right direction would be great.
Thanks
0
Comments