Time.Minute
TimeReturns the minute component from a time, datetime, or datetimezone value.
Syntax
Time.Minute(dateTime as any) as nullable numberParameters
| Name | Type | Required | Description |
|---|---|---|---|
dateTime | any | Yes | The time, datetime, or datetimezone value to extract the minute from. |
Return Value
number — The minute component (0 through 59).
Remarks
Time.Minute returns the minute component as a number from 0 to 59 from a time, datetime, or datetimezone value. If the input is null, the function returns null.
Examples
Example 1: Extract minute from OrderLog Timestamp
Table.AddColumn(
Table.SelectColumns(
Table.FirstN(OrderLog, 5),
{"LogID", "Timestamp"}
),
"Minute", each Time.Minute([Timestamp]), Int64.Type
)Result
LogID | Timestamp | Minute | |
|---|---|---|---|
| 1 | L001 | 1/15/2024 9:30:00 AM | 30 |
| 2 | L002 | 1/16/2024 2:15:00 PM | 15 |
| 3 | L003 | 1/18/2024 11:00:00 AM | 0 |
| 4 | L004 | 1/20/2024 8:45:00 AM | 45 |
| 5 | L005 | 2/1/2024 4:20:00 PM | 20 |
Example 2: Extract minute from a scalar time
#table(
type table [Time = time, Minute = number],
{{#time(14, 30, 45), Time.Minute(#time(14, 30, 45))}}
)Result
Time | Minute | |
|---|---|---|
| 1 | 14:30:45 | 30 |
Compatibility
✓ Power BI Desktop✓ Power BI Service✓ Excel Desktop✓ Excel Online✓ Dataflows✓ Fabric Notebooks