Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredJoin us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM. Register now.
Hi
Im having troubles computing a custom column from the following data
| Cust | Loan | Value | Intervall |
| 1 | 5 | 11 | 0-50% |
| 2 | 10 | 12 | 50-100% |
| 3 | 1 | 0 | Blank |
| 4 | 7 | 5 | Above 100% |
New Column = Loan/Value = Blank - Intervall (0-50% or 50-100% or Above 100%)
I got an infinity problem. Ive tried to use both DIVIDE and IF etc in power query but it seems like its not supported.
let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45WMlTSUTIFYkNDpVidaCUjENMARBiB+cYgJhAbgHkmQJY5WENsLAA=", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [Cust = _t, Loan = _t, Value = _t]),
#"Changed Type" = Table.TransformColumnTypes(Source,{{"Loan", type number}, {"Value", type number}}),
#"Added Custom" = Table.AddColumn(#"Changed Type", "Interval", each if [Value]=0 then null else
if [Loan]/[Value]<= 0.5 then "0-50%" else
if [Loan]/[Value]<= 1 then "50-100%" else
"Above 100%")
in
#"Added Custom"
How to use this code: Create a new Blank Query. Click on "Advanced Editor". Replace the code in the window with the code provided here. Click "Done".
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 75 | |
| 36 | |
| 31 | |
| 29 | |
| 26 |