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

Get inspired! Check out the entries from the Power BI DataViz World Championships preliminary rounds and give kudos to your favorites. View the vizzies.

Reply
harryli
Helper II
Helper II

Get the certain index value

harryli_0-1663130175246.png

Dear all,

as you may see in the above picture of column[current - consult].

I would like to make a column the value will be like the following:

New current - consult

22

32

null

15

39

Thanks

1 ACCEPTED SOLUTION
harryli
Helper II
Helper II

I make the new column be like:

((Time.Hour(DateTime.LocalNow()) - Time.Hour([CONSULT_TIME]))*60)
+((Time.Minute(DateTime.LocalNow()) - Time.Minute([CONSULT_TIME])))

to solve my problem, thanks all.

View solution in original post

3 REPLIES 3
harryli
Helper II
Helper II

I make the new column be like:

((Time.Hour(DateTime.LocalNow()) - Time.Hour([CONSULT_TIME]))*60)
+((Time.Minute(DateTime.LocalNow()) - Time.Minute([CONSULT_TIME])))

to solve my problem, thanks all.

Vijay_A_Verma
Super User
Super User

Use this in a custom column

= DateTime.ToText(DateTime.From(Text.Middle([#"current - consult"],2)),"mm")

this method only available to "Import" mode

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

Check out the February 2025 Power BI update to learn about new features.

March2025 Carousel

Fabric Community Update - March 2025

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

Top Solution Authors