Newbies sokabs Posted October 31, 2003 Newbies Posted October 31, 2003 Hello all! I need to create a calculation or script that will accomplish the following: I have a TimeSheet file with fields Activity, Time, and Project ID. The TimeSheet file has multiple entries relating to the same Project ID, and there are multiple instances of each Activity for each Project ID. I need to find all instances of each Activity for a specific Project ID and then add up the total hours spent on that specific Activity, for that specific Project to create line items in an invoice. I cannot have multiple line items for Design, for instance.... simply a sum of all hours spent on the Design Activity. Any assistance would be GREATLY appreciated. Thank You!
djgogi Posted November 3, 2003 Posted November 3, 2003 First define an calculated field selfIDActivity=ID & " " " Activity. Then define an self relationship "selfActID" using the above field on both side of this rel. Finally define all your calcs thru aggregate functions and the above rel, for ex: timeSpent=Sum(selfActID::time) would yield total time for all records having the current record projectID and activity. Dj
djgogi Posted November 3, 2003 Posted November 3, 2003 Be aware that I gave you only the basic idea on how to deal with this problem. In reality the file you described should be a join file between Project and Task (Activity) dbs. So one possible solution could be, after defining an relational value list in Projects as use values from field taskID from rel projects (based on projectID), looping on valuelistItems and setting the totals (using an calc similar to one I gave you above) in your report. Dj
Recommended Posts
This topic is 7694 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