# Formula to calculate 2 dates within 5days

Options
edited 10/06/22

Hello,

I would like to write a formula that will calculate 2 dates based on this criteria.

Titled: Percentage of Requests "In Progress" within 5days

• I'm creating a control sheet that includes percentages only
• On a separate (our main sheet where things are tracked) sheet I have a "created date column" and a "date put in progress column".
• On my control sheet i would like it to calculate the percentage of requests put in progress within 5days.

• ✭✭✭✭✭
Options

Can we see some screenshots to better understand it?

• ✭✭✭✭✭
edited 10/06/22
Options

To calculate days you simply do =[date put in progress]@row - [created date column]@row

You can use that in your formulas. Perhaps you can create a checkbox column that says:

=if([date put in progress]@row - [created date column]@row <= 5, 1, 0)

That will flag all rows that meet the requirement of less than 5 days.

Then you can use that and divide the number of flags by the count of the total number of rows to get percentage.

• Options

neither worked but thanks for trying :)

• Options

neither worked but thanks for trying :)

• Options

based on the screen shot ive only been able to solve 1 part of the formula and get it to only count the requests assigned. I need to to count the number of requests that took longer that 5 days to be put in progress.

## Help Article Resources

Want to practice working with formulas directly in Smartsheet?

Check out the Formula Handbook template!