Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
kaumil2001
Regular Visitor

Need "Total Loans" as additional Column in Matrix visualization "Exception to Guidelines"

Hello -

 

Req. screenshot to add Total Loans:-

kaumil2001_0-1634102182507.png

 

SQL code for each month values are here:-

SELECT CAST(DATEADD(m, DATEDIFF(m, 0, loandim.[booking_dt]), 0) AS date) AS [booking_dt], COUNT(*) AS [Loans] FROM [dbo].[loan_account_dim] AS loandim INNER JOIN [dbo].[application_dim] AS appdim ON appdim.[id] = loandim.[application_id] GROUP BY CAST(DATEADD(m, DATEDIFF(m, 0, loandim.[booking_dt]), 0) AS date) ORDER BY CAST(DATEADD(m, DATEDIFF(m, 0, loandim.[booking_dt]), 0) AS date)

 

Above query values are here:-

kaumil2001_1-1634102473482.png

 

 

 

Thank You

gk03

1 ACCEPTED SOLUTION
v-chenwuz-msft
Community Support
Community Support

Hi @kaumil2001 

Didn't you already get the results, I see total in the pbix file you provided, at the bottom.

 

I'm not sure if I'm understanding you correctly.

vchenwuzmsft_0-1634284512060.png

 

I put the pbix file in the end you can reference.

 

Best Regards

Community Support Team _ chenwu zhu

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

5 REPLIES 5
v-chenwuz-msft
Community Support
Community Support

Hi @kaumil2001 

Didn't you already get the results, I see total in the pbix file you provided, at the bottom.

 

I'm not sure if I'm understanding you correctly.

vchenwuzmsft_0-1634284512060.png

 

I put the pbix file in the end you can reference.

 

Best Regards

Community Support Team _ chenwu zhu

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

kaumil2001
Regular Visitor

@kaumil2001 , I doubt you can get the display you want. There is an option - Show on row. That move measures on row. But this is different from that

 

We usually use a hybrid table workaround. But  I doubt in this case

 

if you are looking for a Hybrid display with Matrix Column and measure
https://community.powerbi.com/t5/Community-Blog/Creating-a-custom-or-hybrid-matrix-in-PowerBI/ba-p/1...
https://community.powerbi.com/t5/Quick-Measures-Gallery/The-New-Hotness-Custom-Matrix-Hierarchy/m-p/...

vote for Hybrid Table
https://ideas.powerbi.com/ideas/idea/?ideaid=9bc32b23-1eb1-4e74-8b34-349887b37ebc

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

@amitchandak 

I'm able to display "Total Loans" in the .pbix file below but I'm not sure how to display the values correctly,

kaumil2001_2-1634188688921.png

Values I'm looking are from the below SQL query:-
SELECT CAST(DATEADD(m, DATEDIFF(m, 0, loandim.[booking_dt]), 0) AS date) AS [booking_dt],
COUNT(*) AS [Loans]
FROM [dbo].[loan_account_dim] AS loandim
INNER JOIN [dbo].[application_dim] AS appdim ON appdim.[id] = loandim.[application_id]
GROUP BY CAST(DATEADD(m, DATEDIFF(m, 0, loandim.[booking_dt]), 0) AS date)
ORDER BY CAST(DATEADD(m, DATEDIFF(m, 0, loandim.[booking_dt]), 0) AS date)

kaumil2001_1-1634188610191.png


Once correct Total Loans values are displayed I need to use as denomater for the % column in the above screenshot, eg. for Aug 2020 month for "FICO < Min Required" % column will be 26/29 = 89.66%

Hope it makes sense, let me know how to achieve it?

Hello again,

 

kaumil2001_0-1634195339023.png

 

1. Based on my above SQL query, I was trying to display 29 & 33 for Total Rows Matrix Column for Aug 2020 & Sep 2020 month.

 

2. Also, I was trying display % Matrix Values by calulation as # / Total Loans for all the exception rules.

 

Thanks in advance

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.