This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. We're covering it all. You won't want to miss it.
Learn moreGet Fabric Certified for FREE during AI Skills Fest. This week only. Secure your voucher now.
Hi All!
I'm new to PowerBi and I'm trying to implement an insurance dashboard.
All is fine, but now I'm trying to implement the loss ratio formula controled by a slicer filled with my Dates table.
For those who are new to insurance, the Premium (Sales) is Earned over the period of the insurance policy.
Example: an annual premium of $1000, at the 6 months of coverage the Earned Premium is $500 and $83.33 per month if coverage starts the 1st day of the month.
In my mind, the formula I have to implement is something like this:
Premium Per Day = PremiumTable[PremiumAmt] / Datediff(In Days, PremiumTable[EffectiveDate], PremiumTable[ExpirationDate])
Earned Premium for Selected Period = [Premium Per Day] * Datediff(In Days, Higher Date between DatesTable[Date] and PremiumTable[EffectiveDate], Lower Date between DatesTable[Date] and PremiumTable[ExpirationDate])
Acumulated Earned Premium = [Premium Per Day] * Datediff(In Days, PremiumTable[EffectiveDate], DatesTable[Date])
Thank you for your comments!!
Solved! Go to Solution.
Hi Dale,
I have been thinking about this, and I finally understood that my data model was wrong.
Now the model has the info "flat" month by month, and I let Power Bi do just aggregations.
With this model now I can see the Earned Premium month by month, and calculate the Loss Ratio change month by month.
Thank you Dale for your help!!
Gus.
@spuder why do you say datediff wont return the number of days? that is the point of datediff i.e the differences in the date and the interval will be specified by you
example
https://blog.crossjoin.co.uk/2015/06/22/using-datediff-to-calculate-time-intervals-in-dax/
or do i misunderstand what you are saying?
Proud to be a Super User!
Oh I totally apologize for my mistake. I mixed it up with dateadd()
You are totally right with your explanation. Thanks for your help. So @gguadalupe forgot what I said.
Check out the May 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
| User | Count |
|---|---|
| 25 | |
| 24 | |
| 22 | |
| 21 | |
| 19 |
| User | Count |
|---|---|
| 52 | |
| 48 | |
| 47 | |
| 22 | |
| 21 |