Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi Community,
I have an interesting challenge for us to discover. The following table has been built in a different BI platform. I am replicating into my Power BI Dashboard. Here's the challenge, the line headers are built based on a group of if statements that slice the type of data that each will consider. Here's the sample:
"If(([Detalhe_Processos.Tipo_Processo_SGC]='EVE' OR [Detalhe_Processos.Tipo_Processo_SGC]='CMP' OR [Detalhe_Processos.Tipo_Processo_SGC]='FTR' OR [Detalhe_Processos.Tipo_Processo_SGC]='EXC'),'Evolutiva',
If(([Detalhe_Processos.Tipo_Processo_SGC]='TPS'),'Trabalhos Preparatórios', etc "
Anyone knows how to replicate this in DAX?
Thank you in advance!
Hi @Anonymous ,
Is "Detalhe_Processos.Tipo_Processo_SGC" a column name in source data table? If so, you could group this column by creating a calculated column:
Group = IF ( Detalhe_Processos[Tipo_Processo_SGC] = 'EVE' || Detalhe_Processos[Tipo_Processo_SGC] = 'CMP' || Detalhe_Processos[Tipo_Processo_SGC] = 'FTR' || Detalhe_Processos[Tipo_Processo_SGC] = 'EXC', "Evolutiva", IF ( Detalhe_Processos[Tipo_Processo_SGC] = 'TPS', "Trabalhos Preparatórios", "Other" ) )
For more advice, please provide sample data in source table and show us your expected output as suggested in this link.
Best regards,
Yuliana Gu
Hi @Anonymous,
In Power BI, you can still use above IF statement to create a calculated column in data table, then, add this new column into "Columns" of a Matrix visual, and place corresponding fields into "Rows" and "Values". "Values" will be sumed up based on row and column automatically.
Best regards,
Yuliana Gu
If I am understanding your need correctly, you would want to use the Detalhe_Processos.Tipo_Processo_SGC to create a Group. Then you would use that Group for your rows.
Exactly, there are multiple "Tipo_Processo_SGC", I would need to group them differently and then use them as dimension line in my table.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
110 | |
99 | |
80 | |
64 | |
57 |
User | Count |
---|---|
145 | |
110 | |
91 | |
84 | |
66 |