Updated on

Time.ToRecord is a Power Query M function that converts a time value into a record containing its parts. The function returns a record with the parts of the given time value.

Compatible with: Power BI Service Power BI Desktop Excel Microsoft 365


Time.ToRecord( time as time ) as record


Returns a record containing the parts of the given Time value, time.

  • time: A time value for from which the record of its parts is to be calculated.


Convert the #time( 11, 56, 2 ) value into a record containing Time values.

Time.ToRecord( #time( 11, 56, 2 ) )

 /* Output: 
      Hour = 11,
      Minute = 56,
      Second = 2

Other functions related to Time.ToRecord are:

Contribute » | Contributors: Rick de Groot
Microsoft documentation: https://learn.microsoft.com/en-us/powerquery-m/time-torecord