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.
Hola buenas noches,
Por favor alguien que me pueda ayudar con esta consulta. En la siguiente data manejo información de proyectos y cada proyecto tiene identificado riesgos, los cuales se han segmentado en Tipo de riesgo 1, Detalle de riesgo 1 y responsable de riesgo 1. El mismo criterio se aplica cuando queremos registrar el 2do riesgo.
Pregunta: Cómo puedo contar estos riesgos en un tablero. Cómo puedo cuantificar el detalle de esos riesgos y sus responsables, dado que manejo varias columnas de información .
Saludos
Andrea
PROYECTO | TIPO RIESGO 1 | DETALLE RIESGO 1 | RESP RIESGO 1 | TIPO RIESGO 2 | DETALLE RIESGO 2 | RESP RIESGO 2 |
AAA | NOVEDAD_PREVENTA | FALTA CONTRATO FIRMADO | COM | NOVEDAD_PREVENTA | NOVEDADES EN DISEÑO-HLD | C&D |
BBB | NOVEDAD_PLANIFICACION | RETRASO EN EJECUCION DE CRONOGRAMA | PMO | CAMBIOS_ALCANCE | CLIENTE SOLICITA AJUSTES AL ALCANCE | COM |
CCC | NOVEDAD_DESPLIEGUE | RETRASO X TRABAJOS/OBRA CIVIL CLIENTE | CLIENTE | NOVEDAD_COMPRAS | RETRASO X FALTA DE COTIZACION/AF | C&D |
Solved! Go to Solution.
Hola
Los datos se deben transformar tal y como se muestra en de la imagen de abajo. Este código M provoca la transformación
let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("bZDBasNADER/Rew5Jd8ga2Vbye7KWa3tFBNCoYUGSk75f+ptSfGh1xnNzEPL4hDR7VzSiT3665B54lSqFMVMUgcmXWIPpKlkpLI68+3x+X/Gc71+6YOHxLOtCsHb/R28u+wW1zTNNhYwSSuEJJp+sgFfQRJQnzVplzECn5nG8usPUWsfxkbUrhgIE3FVRisaOUPm08hWDNAfVi2uTAZFofQMRjrwE72yENGGZeUegnA38h/IGQ7a2J5kkgCz5iM8h+rm1+3j/tgUkMYho23SAekI2sJp1MJ7bLe/uHwD", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type text) meta [Serialized.Text = true]) in type table [Project = _t, #"RISK TYPE 1" = _t, #"RISK DETAIL 1" = _t, #"RISK 1" = _t, #"RISK TYPE 2" = _t, #"RISK DETAIL 2" = _t, #"RISK 2" = _t]),
#"Changed Type" = Table.TransformColumnTypes(Source,{{"Project", type text}, {"RISK TYPE 1", type text}, {"RISK DETAIL 1", type text}, {"RISK 1", type text}, {"RISK TYPE 2", type text}, {"RISK DETAIL 2", type text}, {"RISK 2", type text}}),
#"Unpivoted Other Columns" = Table.UnpivotOtherColumns(#"Changed Type", {"Project"}, "Attribute", "Value"),
#"Split Column by Delimiter" = Table.SplitColumn(#"Unpivoted Other Columns", "Attribute", Splitter.SplitTextByEachDelimiter({" "}, QuoteStyle.Csv, true), {"Attribute.1", "Attribute.2"}),
#"Changed Type1" = Table.TransformColumnTypes(#"Split Column by Delimiter",{{"Attribute.1", type text}, {"Attribute.2", Int64.Type}}),
#"Pivoted Column" = Table.Pivot(#"Changed Type1", List.Distinct(#"Changed Type1"[Attribute.1]), "Attribute.1", "Value"),
#"Removed Columns" = Table.RemoveColumns(#"Pivoted Column",{"Attribute.2"})
in
#"Removed Columns"
Espero que esto ayude.
Hola
Realmente no sé cómo ayudarte. Usted sólo debe ser capaz de descargar el archivo y al hacer doble clic en él debe abrirse en PowerBI Desktop. También estoy adjuntando el archivo para su referencia.
Hola @abadill
Ashish_Mathur archivo pbix funciona bien de mi lado, si usted podría utilizar esta manera para abrir el archivo en el escritorio power bi
File->Open->Browse y, a continuación, elija este archivo.
y para su requisito, necesita depivote y pivotar su tabla en la consulta de energía, aquí está el blog, por favor refiérase a él:
https://radacad.com/pivot-and-unpivot-with-power-bi
Saludos
Lin
Hola
Los datos se deben transformar tal y como se muestra en de la imagen de abajo. Este código M provoca la transformación
let
Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("bZDBasNADER/Rew5Jd8ga2Vbye7KWa3tFBNCoYUGSk75f+ptSfGh1xnNzEPL4hDR7VzSiT3665B54lSqFMVMUgcmXWIPpKlkpLI68+3x+X/Gc71+6YOHxLOtCsHb/R28u+wW1zTNNhYwSSuEJJp+sgFfQRJQnzVplzECn5nG8usPUWsfxkbUrhgIE3FVRisaOUPm08hWDNAfVi2uTAZFofQMRjrwE72yENGGZeUegnA38h/IGQ7a2J5kkgCz5iM8h+rm1+3j/tgUkMYho23SAekI2sJp1MJ7bLe/uHwD", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type text) meta [Serialized.Text = true]) in type table [Project = _t, #"RISK TYPE 1" = _t, #"RISK DETAIL 1" = _t, #"RISK 1" = _t, #"RISK TYPE 2" = _t, #"RISK DETAIL 2" = _t, #"RISK 2" = _t]),
#"Changed Type" = Table.TransformColumnTypes(Source,{{"Project", type text}, {"RISK TYPE 1", type text}, {"RISK DETAIL 1", type text}, {"RISK 1", type text}, {"RISK TYPE 2", type text}, {"RISK DETAIL 2", type text}, {"RISK 2", type text}}),
#"Unpivoted Other Columns" = Table.UnpivotOtherColumns(#"Changed Type", {"Project"}, "Attribute", "Value"),
#"Split Column by Delimiter" = Table.SplitColumn(#"Unpivoted Other Columns", "Attribute", Splitter.SplitTextByEachDelimiter({" "}, QuoteStyle.Csv, true), {"Attribute.1", "Attribute.2"}),
#"Changed Type1" = Table.TransformColumnTypes(#"Split Column by Delimiter",{{"Attribute.1", type text}, {"Attribute.2", Int64.Type}}),
#"Pivoted Column" = Table.Pivot(#"Changed Type1", List.Distinct(#"Changed Type1"[Attribute.1]), "Attribute.1", "Value"),
#"Removed Columns" = Table.RemoveColumns(#"Pivoted Column",{"Attribute.2"})
in
#"Removed Columns"
Espero que esto ayude.
Hola,
La solución que usted publico es exactamente lo que necesito pero al tratar de pasar el código me sale errores de sintaxis. Por favor me puede pasar el archivo , yo utilizo powerbi en español. He estado haciendo varias modificaciones pero no doy con la solución. Me puede pasar a mi correo anbadi@uees.edu.ec o si me lo pasa por algun link no hay problema.
Hola
Puede descargar mi archivo PBI desde aquí.
Espero que esto ayude.
Hola
No puedo abrirlo =( cuando lo abro desde el winrar no me lo reconoce como un archivo de power bi. Que pena , disculpa la molestia será que me puede colcar el paso a paso, de como hacer ese cambio en las columnas.
Gracias
Andrea.
Gracias si me sirvió.
Hola @abadill
Ashish_Mathur archivo pbix funciona bien de mi lado, si usted podría utilizar esta manera para abrir el archivo en el escritorio power bi
File->Open->Browse y, a continuación, elija este archivo.
y para su requisito, necesita depivote y pivotar su tabla en la consulta de energía, aquí está el blog, por favor refiérase a él:
https://radacad.com/pivot-and-unpivot-with-power-bi
Saludos
Lin
Gracias si pude abrir el archivo y la solución si me funcionó.
Hola
Realmente no sé cómo ayudarte. Usted sólo debe ser capaz de descargar el archivo y al hacer doble clic en él debe abrirse en PowerBI Desktop. También estoy adjuntando el archivo para su referencia.
Me sale error de sintaxys. Esto es lo que estoy colocando. Me puede compartir el archivo de ejemplo.
= Table.TransformColumnTypes(#"Encabezados promovidos",{{"PROYECTO", type text}, {"TIPO RIESGO 1", type text}, {"DETALLE RIESGO 1", type text}, {"RESP RIESGO 1", type text}, {"TIPO RIESGO 2", type text}, {"DETALLE RIESGO 2", type text}, {"RESP RIESGO 2", type text}}), ,
#"Changed Type" = Table.TransformColumnTypes(#"Encabezados promovidos",{{"PROYECTO", type text}, {"TIPO RIESGO 1", type text}, {"DETALLE RIESGO 1", type text}, {"RESP RIESGO 1", type text}, {"TIPO RIESGO 2", type text}, {"DETALLE RIESGO 2", type text}, {"RESP RIESGO 2", type text}}), # Table.UnpivotOtherColumns (#"Tipo cambiado"{"PROYECTO"},"ATRIBUTO","VALOR"),# "Splitter.SplitTextByAnyDelimiter" = Table.SplitColumn (#"Unpivoted Other Columns", "ATRIBUTO", Splitter.SplitTextByEachDelimiter({" "}, QuoteStyle.Csv, true), {"ATRIBUTO.1", "ATRIBUTO.2"}), #"Tipo cambiado1" = Table.TransformColumnTypes(#"Split Column by Delimiter",{{"ATRIBUTO.1", type text}, {"ATRIBUTO.2", Int64.Type}}),
#"Pivoted Column" = Table.Pivot(#"Tipo cambiado1", List.Distinct(#"Tipo cambiado1"[ATRIBUTO.1]), "ATRIBUTO.1", "VALOR"),
#"Removed Columns" = Table.RemoveColumns(#"Pivoted Column",{"ATRIBUTO.2"})
in
#"Removed Columns"
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 |
---|---|
2 | |
1 | |
1 | |
1 | |
1 |
User | Count |
---|---|
2 | |
2 | |
2 | |
2 | |
1 |