Hi there, I wish to split the [Moment] colum...

Hi there,

I wish to split the [Moment] column, which is DateTime format --> in 2 columns Day and Hour, with a Number format. I have no problem with the DAY function, result is ok.

1 - But I am struggling with the HOUR([Moment]) formula that returns the error “Parameter 1 of function HOUR is of the wrong type”.

I’ve understood I need to have a Duration type for this function, so I was thinking of calculating duration from 0 to TIME([Moment]) but I cannot define this virtual column as duration.

2 - nor it works if I use the LEFT(TIME([Moment]),2) workaround. Error says “Parameter 1 of function LEFT is of the wrong type”

Do you know what transformation I need to do or if there is an easy formula to split

[Moment] column into its components? I feel so nerd _ Thanks, have a good day.

0 3 589
3 REPLIES 3

The format should be like HOUR(TIME([Moment])-“00:00:00”)

@Aleksi_Alkio gosh, so easy! thanks, it works.

You’re welcome

Top Labels in this Space