Forum Discussion
Anonymous
4 years agoNot applicable
New Column with IF Logic and Excel Syntax
How can I create and add a new column in Power BI to mimick the excel formulas below? =IF(NUMBERVALUE(C2)<=250,"0-250",IF(NUMBERVALUE(C2)<=500,"251-500",IF(NUMBERVALUE(C2)<=750,"501-750",IF(NUMBERV...
- 4 years ago
For First Four, use following DAX formula and change the column to Whole Number
First Four = LEFT('Table'[Phase],4)For Section, use following DAX formula
SWITCH( TRUE(), 'Table'[First Four]<=250,"0-250", 'Table'[First Four]<=500,"251-500", 'Table'[First Four]<=750,"501-750", 'Table'[First Four]<=1000,"751-1000", 'Table'[First Four]<=1250,"1001-1250", 'Table'[First Four]=2000,"2000", 'Table'[First Four]=9000,"9000", LEFT('Table'[First Four],4) )
Vijay_A_Verma
4 years agoMost Valuable Professional
For First Four, use following DAX formula and change the column to Whole Number
First Four = LEFT('Table'[Phase],4)
For Section, use following DAX formula
SWITCH(
TRUE(),
'Table'[First Four]<=250,"0-250",
'Table'[First Four]<=500,"251-500",
'Table'[First Four]<=750,"501-750",
'Table'[First Four]<=1000,"751-1000",
'Table'[First Four]<=1250,"1001-1250",
'Table'[First Four]=2000,"2000",
'Table'[First Four]=9000,"9000",
LEFT('Table'[First Four],4)
)