cancel
Showing results for 
Search instead for 
Did you mean: 

How create new date column from date and hours

WaikatoNorthHead
Blue LED

I would like to combine a date column (dd/MM/yyyy) and a separate hours (123) column into a new date format column, that comprise of both the date the hour of the day (dd/MM/yyyy HH:mm)

Labels (1)
0 Kudos
1 Reply
calamari
DataRobot Employee
DataRobot Employee

G'day @WaikatoNorthHead 

Using a Compute Column you can achieve what you're after this way by concatenating the two columns into a single one, and then using the datevalue function:

DATEVALUE(CONCATENATE(@Posting Date (no time)@, " " ,@Posting Time@), "dd/MM/yyyy HHmmss" ) 

calamari_1-1618973589164.png

Given the data:

calamari_0-1618973343407.png

The result would be:

calamari_2-1618973603024.png

Hope that helps (try out creating a filtergram on "datetime" columns if you haven't already)!

Cheers,

Calamari

0 Kudos