Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
All,
PBI newbie here. Maybe I'm missing something, not real sure, but I have a measure that I'm using to calculate the average age of an opportunity from our CRM data. It works when coupled with opportunities that have both a createdon date and an actualclosedate; these are both columns in my table. I created another column with the Today() function as the value. What I'm trying to accomplish is show the average age based on the dates(createdon vs today's date, or createdon vs actualclose date) of each opportunity. Thoughts?
Current working formula:
Avg Age = AVERAGEX (opportunity, DATEDIFF ( [createdon], [actualclosedate], DAY)
Tried:
Opp Avg Age = AVERAGEX (opportunity, DATEDIFF ([created on], [today], DAY) >>> The result I get is ever single column added up and averaged (so instead of individual number of days per opportunity, it's just entire column added and averaged)
Solved! Go to Solution.
Hi @swebb
please try
Avg Age =
AVERAGEX (
opportunity,
DATEDIFF ( [createdon], COALESCE ( [actualclosedate], TODAY () ), DAY )
)
Hi @swebb
please try
Avg Age =
AVERAGEX (
opportunity,
DATEDIFF ( [createdon], COALESCE ( [actualclosedate], TODAY () ), DAY )
)
Actually, I think we can mark this resolved. I was looking through the records and have determined the counts are accurate. Thank you!
A bit closer, maybe. Still getting some really odd numbers, in to the thousands.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
10 | |
9 | |
8 | |
8 | |
8 |
User | Count |
---|---|
13 | |
12 | |
11 | |
10 | |
8 |