Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Formula in structure plugin with -4w not working

rupert_schreder
Contributor
March 21, 2022

Hey together,

I'd like to count the in the last 4 weeks created issues via a formula in the JIRA structure plugin

This formula does unfortunately not work:  SUM{If(created >= "-4w";1)}

With absolute date's it is working: SUM{If(created >= DATE("2022-03-01");1)}

But I'd like to avoid absolute dates.. Any ideas?

Regards

Rupert

1 answer

1 accepted

3 votes
Answer accepted
David Niro
Atlassian Partner
March 21, 2022

Hello @rupert_schreder ,

David from ALM Works here.  Welcome to the Community!

For this, you will want to use the DAYS_BETWEEN function to calculate the days between your created date and today.  We can then compare this to your 4w, which we need to identify in days.

It should look something like this:

SUM{IF(DAYS_BETWEEN(created,Today())> 28,1)}

Please let me know if it works for you!

Best Regards,
David

rupert_schreder
Contributor
March 21, 2022

Thanks a lot David, works fine..
I only needed to change the ">" comparison to a "<" comparison.

Thx a lot!

Regards

Rupert

Like # people like this

Suggest an answer

Log in or Sign up to answer