The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
I am wanting to see which Policies have the same Date Cancelled (Year and Month) and a Date of loss (Year and Month)
Solved! Go to Solution.
Hi @simonandtony
You can create a calculated column:
Matching =
VAR cancelYear = YEAR(Table[DateCancelled_notime])
VAR cancelMonth = MONTH(Table[DateCancelled_notime])
VAR lossYear = YEAR(Table[DateOfLoss])
VAR lossMonth = MONTH(Table[DateOfLoss])
RETURN
IF(cancelYear = lossYear && cancelMonth = lossMonth, "Match", "No match")
Proud to be a Super User! | |
Hello @simonandtony ,
1. Go to the Modeling tab in Power BI and create two calculated columns:
For Datecancelled:
YearMonth_Cancelled = FORMAT([DateCancelled_notime], "YYYY-MM")
For Dateofloss
YearMonth_Loss = FORMAT([DateOfLoss], "YYYY-MM")
2. Create another calculated column to check if the YearMonth_Cancelled is equal to YearMonth_Loss:
SameYearMonth = IF([YearMonth_Cancelled] = [YearMonth_Loss], "Same Month", "Different Month")
3. Add this SameYearMonth column to your report to easily filter or identify policies where the cancellation and loss occurred in the same year and month.
If you find this helpful , please mark it as solution which will be helpful for others and Your Kudos/Likes 👍 are much appreciated!
Thank You
Dharmendar S
Hello @simonandtony ,
1. Go to the Modeling tab in Power BI and create two calculated columns:
For Datecancelled:
YearMonth_Cancelled = FORMAT([DateCancelled_notime], "YYYY-MM")
For Dateofloss
YearMonth_Loss = FORMAT([DateOfLoss], "YYYY-MM")
2. Create another calculated column to check if the YearMonth_Cancelled is equal to YearMonth_Loss:
SameYearMonth = IF([YearMonth_Cancelled] = [YearMonth_Loss], "Same Month", "Different Month")
3. Add this SameYearMonth column to your report to easily filter or identify policies where the cancellation and loss occurred in the same year and month.
If you find this helpful , please mark it as solution which will be helpful for others and Your Kudos/Likes 👍 are much appreciated!
Thank You
Dharmendar S
Hi @simonandtony
You can create a calculated column:
Matching =
VAR cancelYear = YEAR(Table[DateCancelled_notime])
VAR cancelMonth = MONTH(Table[DateCancelled_notime])
VAR lossYear = YEAR(Table[DateOfLoss])
VAR lossMonth = MONTH(Table[DateOfLoss])
RETURN
IF(cancelYear = lossYear && cancelMonth = lossMonth, "Match", "No match")
Proud to be a Super User! | |
User | Count |
---|---|
26 | |
10 | |
8 | |
6 | |
6 |
User | Count |
---|---|
31 | |
11 | |
10 | |
10 | |
9 |