snekkis Posted July 1, 2003 Posted July 1, 2003 This is a new area in FM for me even if it is, I believe, one of the most basic in db. I try to make total field that only gives the total based upon present year, so when the next year come the total shows only total based upon invoices from that new year. I have seen db examples in the FM extras folder where you make reports with scripts to give totals. That is not an option. What I'm thinking about is if it was possible to use the formulas to achieve this? Thanks!
LaRetta Posted July 1, 2003 Posted July 1, 2003 Hi Snekkis, You might consider isolating your summaries by using a relationship. Left Key global (year) or unstored calc with Year(Status(CurrentDate)) Right Key calculation (index ON) = Year(InvoiceDateField) Then base your summaries on the new relationship. If you use a global, you can populate it with Year(Status(CurrentDate)) upon db Startup or allow Users to enter a year during your report script process LaRetta
snekkis Posted July 1, 2003 Author Posted July 1, 2003 I got it! But not as I hoped for. I did what I understood and made a startup script. Thanks for helping me to think! For others convenience, or for those who want to polish my solution, here is what I did and what worked for me: Go to Layout["FindLayout"] Enter Find Mode [Restore] Perform Find/Replace[No dialog, "InvoiceYear", "","Find Next"] Perform Find[Restore, Replace Found Set] Set Field["GlobalTotal", "Get record summary"] Show All Record Go to Layout [Refresh window, "Main"] Feels good!
Recommended Posts
This topic is 7886 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now