Summarize duration in a project sheet by week/date range?

Is there a way to summarize the DURATION data in a resource-enabled project sheet by week or a given date range? i.e., I want to see total hours for the last week by person. I already have a helper column inserted which converts DURATION to hours.

Thanks!

Answers

  • M Underbrink
    M Underbrink ✭✭✭✭✭

    =SUMIF(AND([DateColumn]@row < TODAY(), [DateColumn]@row TODAY(-7)), [HoursColumnYouWanToSum])

    Something similar to this could work. If you wanted to do it for multiple people on a sheet, you'd have to have a rollup/calculation grid, with all of their names on it, but have the sumIF check for the additional condition in which the "Assigned to" column checked if they were that person

    =SUMIF(AND([AssignedToColumFromOthersheet]=[AssignedTo]@row, [DateColumn]@row < TODAY(), [DateColumn]@row TODAY(-7)), [HoursColumnYouWanToSum])

    Let me know if further clarification is needed!

  • Gordon
    Gordon ✭✭✭✭✭

    @M UnderbrinkThank you for the suggestion. Regarding the [Date Column] reference, because these are resource-enabled project sheets, I have two columns: [Start Date] and [End Date].


    Using your formula as a starting point, do you think this would work if I made it a SUMIFS instead with an AND for both dates:

    =SUMIFS(AND([Start Date]@row < TODAY(), [Start Date]@row

    The only problem I keep running into is how to get the [Duration] to be only for the week period if the [Start Date] and [End Date] are longer or shorter than one week. At first I thought I could use NETWORKDAYS, but I couldn't get the formula logic to work based on the [Start Date], [End Date] and last week parameters.

  • M Underbrink
    M Underbrink ✭✭✭✭✭

    Starting to get a little too into specifics for me to be able to solve through a chat forum....

    When things start getting too complex, I start to look at why I'm measuring something and if there is an easier way to measure it. If you never want the duration of any given column to count beyond 40 hours for your formula, then I would focus my efforts on restricting the duration column I'm summing to a max of 40 through formulas. Would that work for your purposes? You could have a second column next to Duration that "Max 40 Duration" with the column formula as follows,

    =IF([Duration]@row<40, [Duration], 40)

    Also, I don't think my solution works as is - it may need some additional tweaking....

Help Article Resources

Want to practice working with formulas directly in Smartsheet?

Check out the公式手册模板!
Try omitting the \"*100\" at the end of your formula. Convert the column to show the number as a percentage. <\/p>
\n
\n \n \"Screenshot<\/img><\/a>\n <\/div>\n<\/div>\n


<\/p>"}]}},"status":{"statusID":3,"name":"Accepted","state":"closed","recordType":"discussion","recordSubType":"question"},"bookmarked":false,"unread":false,"category":{"categoryID":322,"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions","allowedDiscussionTypes":[]},"reactions":[{"tagID":3,"urlcode":"Promote","name":"Promote","class":"Positive","hasReacted":false,"reactionValue":5,"count":0},{"tagID":5,"urlcode":"Insightful","name":"Insightful","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":11,"urlcode":"Up","name":"Vote Up","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":13,"urlcode":"Awesome","name":"Awesome","class":"Positive","hasReacted":false,"reactionValue":1,"count":0}],"tags":[]},{"discussionID":107015,"type":"question","name":"Coiuntifs Formula Help Needed","excerpt":"Hi! Can anyone please assist with the correct Formula? i'm trying to count how many rows are on a sheet(Reference Sheet) the criterea for the rows are as follows: =countifs STATUS Column is \"Discharged\" or \"ACTIVE\" , Discharged\/Nonadmit Column is Greater than 05\/19\/2023 and Date activated column is less than 05\/27\/2023 I…","snippet":"Hi! Can anyone please assist with the correct Formula? i'm trying to count how many rows are on a sheet(Reference Sheet) the criterea for the rows are as follows: =countifs STATUS…","categoryID":322,"dateInserted":"2023-06-28T13:59:55+00:00","dateUpdated":null,"dateLastComment":"2023-06-28T14:35:02+00:00","insertUserID":162885,"insertUser":{"userID":162885,"name":"Ymandel","title":"President","url":"https:\/\/community.smartsheet.com\/profile\/Ymandel","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-06-28T15:31:58+00:00","banned":0,"punished":0,"private":false,"label":"✭"},"updateUserID":null,"lastUserID":162885,"lastUser":{"userID":162885,"name":"Ymandel","title":"President","url":"https:\/\/community.smartsheet.com\/profile\/Ymandel","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-06-28T15:31:58+00:00","banned":0,"punished":0,"private":false,"label":"✭"},"pinned":false,"pinLocation":null,"closed":false,"sink":false,"countComments":3,"countViews":25,"score":null,"hot":3375925497,"url":"https:\/\/community.smartsheet.com\/discussion\/107015\/coiuntifs-formula-help-needed","canonicalUrl":"https:\/\/community.smartsheet.com\/discussion\/107015\/coiuntifs-formula-help-needed","format":"Rich","lastPost":{"discussionID":107015,"commentID":382847,"name":"Re: Coiuntifs Formula Help Needed","url":"https:\/\/community.smartsheet.com\/discussion\/comment\/382847#Comment_382847","dateInserted":"2023-06-28T14:35:02+00:00","insertUserID":162885,"insertUser":{"userID":162885,"name":"Ymandel","title":"President","url":"https:\/\/community.smartsheet.com\/profile\/Ymandel","photoUrl":"https:\/\/us.v-cdn.net\/6031209\/uploads\/defaultavatar\/nWRMFRX6I99I6.jpg","dateLastActive":"2023-06-28T15:31:58+00:00","banned":0,"punished":0,"private":false,"label":"✭"}},"breadcrumbs":[{"name":"Home","url":"https:\/\/community.smartsheet.com\/"},{"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions"}],"groupID":null,"statusID":3,"attributes":{"question":{"status":"accepted","dateAccepted":"2023-06-28T14:22:57+00:00","dateAnswered":"2023-06-28T14:10:08+00:00","acceptedAnswers":[{"commentID":382838,"body":"

@Ymandel<\/a> See if this version works:<\/p>

=COUNTIFS([Discharged Date]:[Discharged Date], >DATE(2023, 5, 26), [Date Activated]:[Date Activated], <=(DATE(2023, 6, 2)), [Status]:[Status], OR(@cell = \"Active\", @cell = \"Discharged\"))<\/p>"}]}},"status":{"statusID":3,"name":"Accepted","state":"closed","recordType":"discussion","recordSubType":"question"},"bookmarked":false,"unread":false,"category":{"categoryID":322,"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions","allowedDiscussionTypes":[]},"reactions":[{"tagID":3,"urlcode":"Promote","name":"Promote","class":"Positive","hasReacted":false,"reactionValue":5,"count":0},{"tagID":5,"urlcode":"Insightful","name":"Insightful","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":11,"urlcode":"Up","name":"Vote Up","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":13,"urlcode":"Awesome","name":"Awesome","class":"Positive","hasReacted":false,"reactionValue":1,"count":0}],"tags":[]},{"discussionID":107013,"type":"question","name":"#Incorrect Argument Set","excerpt":"Good Morning, I've been trying to figure this formula out but I can't seem to get it. I need to sum any amount in the computed count column, match it with the AP tech for a specific month. I've tried swapping the columns around but nothing seems to work. What am I missing? =SUMIFS({011-AP Archive AP Tech}, [Primary…","snippet":"Good Morning, I've been trying to figure this formula out but I can't seem to get it. I need to sum any amount in the computed count column, match it with the AP tech for a…","categoryID":322,"dateInserted":"2023-06-28T13:44:50+00:00","dateUpdated":null,"dateLastComment":"2023-06-28T14:41:30+00:00","insertUserID":156010,"insertUser":{"userID":156010,"name":"AliT","url":"https:\/\/community.smartsheet.com\/profile\/AliT","photoUrl":"https:\/\/aws.smartsheet.com\/storageProxy\/image\/images\/u!1!80tRN2Ch-HQ!nDHdH1rxiPw!1_-nYVqJJzq","dateLastActive":"2023-06-28T14:41:41+00:00","banned":0,"punished":0,"private":false,"label":"✭✭"},"updateUserID":null,"lastUserID":156010,"lastUser":{"userID":156010,"name":"AliT","url":"https:\/\/community.smartsheet.com\/profile\/AliT","photoUrl":"https:\/\/aws.smartsheet.com\/storageProxy\/image\/images\/u!1!80tRN2Ch-HQ!nDHdH1rxiPw!1_-nYVqJJzq","dateLastActive":"2023-06-28T14:41:41+00:00","banned":0,"punished":0,"private":false,"label":"✭✭"},"pinned":false,"pinLocation":null,"closed":false,"sink":false,"countComments":1,"countViews":16,"score":null,"hot":3375923780,"url":"https:\/\/community.smartsheet.com\/discussion\/107013\/incorrect-argument-set","canonicalUrl":"https:\/\/community.smartsheet.com\/discussion\/107013\/incorrect-argument-set","format":"Rich","lastPost":{"discussionID":107013,"commentID":382850,"name":"Re: #Incorrect Argument Set","url":"https:\/\/community.smartsheet.com\/discussion\/comment\/382850#Comment_382850","dateInserted":"2023-06-28T14:41:30+00:00","insertUserID":156010,"insertUser":{"userID":156010,"name":"AliT","url":"https:\/\/community.smartsheet.com\/profile\/AliT","photoUrl":"https:\/\/aws.smartsheet.com\/storageProxy\/image\/images\/u!1!80tRN2Ch-HQ!nDHdH1rxiPw!1_-nYVqJJzq","dateLastActive":"2023-06-28T14:41:41+00:00","banned":0,"punished":0,"private":false,"label":"✭✭"}},"breadcrumbs":[{"name":"Home","url":"https:\/\/community.smartsheet.com\/"},{"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions"}],"groupID":null,"statusID":3,"attributes":{"question":{"status":"accepted","dateAccepted":"2023-06-28T14:41:39+00:00","dateAnswered":"2023-06-28T14:41:30+00:00","acceptedAnswers":[{"commentID":382850,"body":"

with a little more work - I got it!!<\/p>

=SUMIFS({011-AP Archive Computed Count}, {011-AP Archive AP Tech}, [Primary Column]118, {011-AP Archive Month}, 3)<\/p>

I swear I tried this earlier!! But I did confirm that it is adding up correctly!!<\/p>"}]}},"status":{"statusID":3,"name":"Accepted","state":"closed","recordType":"discussion","recordSubType":"question"},"bookmarked":false,"unread":false,"category":{"categoryID":322,"name":"Formulas and Functions","url":"https:\/\/community.smartsheet.com\/categories\/formulas-and-functions","allowedDiscussionTypes":[]},"reactions":[{"tagID":3,"urlcode":"Promote","name":"Promote","class":"Positive","hasReacted":false,"reactionValue":5,"count":0},{"tagID":5,"urlcode":"Insightful","name":"Insightful","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":11,"urlcode":"Up","name":"Vote Up","class":"Positive","hasReacted":false,"reactionValue":1,"count":0},{"tagID":13,"urlcode":"Awesome","name":"Awesome","class":"Positive","hasReacted":false,"reactionValue":1,"count":0}],"tags":[]}],"initialPaging":{"nextURL":"https:\/\/community.smartsheet.com\/api\/v2\/discussions?page=2&categoryID=322&includeChildCategories=1&type%5B0%5D=Question&excludeHiddenCategories=1&sort=-hot&limit=3&expand%5B0%5D=all&expand%5B1%5D=-body&expand%5B2%5D=insertUser&expand%5B3%5D=lastUser&status=accepted","prevURL":null,"currentPage":1,"total":10000,"limit":3},"title":"Trending in Formulas and Functions ","subtitle":null,"description":null,"noCheckboxes":true,"containerOptions":[],"discussionOptions":[]}">

Trending in Formulas and Functions