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

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.

Reply
Syndicate_Admin
Administrator
Administrator

Extraiga la fecha y hora ISO 8601 y conviértala al formato de fecha y hora

Breve explicación de la situación inicial: Tengo una tabla en la que vuelven las respuestas. Además, recibo la información sobre el tipo de datos de la respuesta. Además, obtengo la información hasta que se debe verificar la respuesta. El campo "Desde" se da en formato de fecha y hora ISO 8601. Power BI reconoce el formato ISO y lo formatea correctamente.

HastaDatatypeRespuestas
2018-12-05T00:00:00.0000000+00:00CUERDAEste es un test
2019-12-05T00:00:00.0000000+00:00INT500
2020-12-05T00:00:00.0000000+00:00FECHA Y HORA2018-12-05T00:00:00.0000000+00:00

Ahora me gustaría extraer el DATETIME de las respuestas y también formatearlo, pero desafortunadamente recibo el siguiente mensaje de error.

DerMoe_0-1646230921319.png

¿Alguien aquí tiene una solución o tiene un problema similar?

1 ACCEPTED SOLUTION
Syndicate_Admin
Administrator
Administrator

Hola, @DerMoe
Aquí está en Power Query:

vojtechsima_0-1646231480460.png

    #"Added Custom" = Table.AddColumn(#"Changed Type1", "TransformedAnswer", each if [Datatype] = "DATETIME" then [Answers] else null),
    #"Changed Type2" = Table.TransformColumnTypes(#"Added Custom",{{"TransformedAnswer", type datetime}})
in
    #"Changed Type2"

View solution in original post

3 REPLIES 3
Syndicate_Admin
Administrator
Administrator

Hola, @DerMoe
Aquí está en Power Query:

vojtechsima_0-1646231480460.png

    #"Added Custom" = Table.AddColumn(#"Changed Type1", "TransformedAnswer", each if [Datatype] = "DATETIME" then [Answers] else null),
    #"Changed Type2" = Table.TransformColumnTypes(#"Added Custom",{{"TransformedAnswer", type datetime}})
in
    #"Changed Type2"

¡UAU! ¡Gracias por esa respuesta realmente rápida! Me ayudaste mucho

@DerMoe
Feliz de ayudar,
si pudieras por favor Kudo mi respuesta para ayudarme, te lo agradecería.
Gracias

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors