How to sum decimal FlowFields from a table for a report?

Rob_Burke
Member Posts: 10
Hi folks,
I have applied all my filters and I've been trying to sum two columns from a table for a report in Navision 3.70b - one was working perfectly but the other kept on returning 0.00, upon further investigation, the only difference I can find between the columns is that one is a Normal Field Type and the other is a FlowField.
Is there a special way of calculating or in some other way summing the total value of flowfields in a table after filters have been applied?
Thanks a million,
Cheers,
Rob
I have applied all my filters and I've been trying to sum two columns from a table for a report in Navision 3.70b - one was working perfectly but the other kept on returning 0.00, upon further investigation, the only difference I can find between the columns is that one is a Normal Field Type and the other is a FlowField.
Is there a special way of calculating or in some other way summing the total value of flowfields in a table after filters have been applied?
Thanks a million,
Cheers,
Rob
0
Answers
-
use CALCFIELDS Function after the filter is applied to calcluate the value of the flowfield..Sandeep B0
-
How can I then sum the value of the calculated fields?
I'm trying the following:// My filters are applied here... TransInfocodeEntry.CALCFIELDS("Discount Amount"); IF TransInfocodeEntry.FIND('-') THEN REPEAT ValueOfStaffDiscounts += TransInfocodeEntry."Discount Amount"; NoOfStaffDiscounts += 1; UNTIL TransInfocodeEntry.NEXT = 0;
ValueOfStaffDiscounts is still staying at 0.00 though?0 -
I actually figured it out myself, the problem seemed to be with *where* I was calling CALCFIELDS.
I modified the code to this:// My filters are applied here... IF TransInfocodeEntry.FIND('-') THEN REPEAT TransInfocodeEntry.CALCFIELDS("Discount Amount"); ValueOfStaffDiscounts += TransInfocodeEntry."Discount Amount"; NoOfStaffDiscounts += 1; UNTIL TransInfocodeEntry.NEXT = 0;
And it's working fine now. Thanks a million for your help mate!0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions