separate date and time in datameer

2 followers
0
Avatar

Hi,

I want o separate date and time in datameer which is in the following format: Jul 26, 2018 04:13:34 AM.

I want to do this to join it  another data on the basis of dates. another data has date in this format: Oct, 15 2002 12:00:00 AM.

Because of the change in time, I am not able to join the datasets.

Pls help with this.

Alka Singh

1 comment

  • Avatar
    Joel Stewart

    This can be done by using the FORMATDATE function to convert the DATETIME objects into a String (or multiple Strings; one for date and one for time). There is not a DATE only or TIME only object in Datameer so if you want to join on just part of the DATETIME object, convert the parts you want to use as your join key into a String object first. 

    For example, if the date is Jul 26, 2018 04:13:34 AM FORMATDATE(#DateColumn;"yyyy-MM-dd") will output "2018-07-26" which can be joined to other dates without the hours, minutes and seconds. 

    1
Please sign in to leave a comment.