Forum Discussion

jdelekta's avatar
jdelekta
Frequent Visitor
3 years ago

Apply DateAdd in Measures

Hello,

 

Please see attached. I am trying to calculate total defections over the last 3 months and total items that were not defects over the last 6 months. I'd ultimately like to divide these and show the changes each month. I created conditional columns in the data set to count the defects ("Defect Count") and everything else in the data ("Not Defect Count"). 

 

I've been using DateAdd but haven't had success. I've noticed that when I go further back in time I end up getting less results.

 

The expected result would be for "Defects Last 3 Months" would be 5 and for "Created Last 6 Months" would be 24. I am assuming it is something with the relationship.

 

Thank you. 

6 Replies