Start a new topic
Answered

Convert Text to Timestamp

For a TimeStamp like '20190301175527', which is shown as a text column in the dataset, what should be done to convert it to a timestamp column ?


Best Answer

Procedure: 

1.   Right click on any cell in that text column.

2.   Select Transform -> Data type. (Refer below pic)


  

                                                    Transforming datatype


3.   Select the data type as TimeStamp.

4.   In the format section, if the 24 hour format is there then input format should be yyyyMMddHHmmss where HH= Hours for 24 hour format. Similarly, for 12 Hours Format, the input format should be yyyyMMddhhmmss where MM is for Month and mm is for minute. 

(Refer below pic)



 

Transforming datatype to 24 Hour format


5.   And click on Apply. (Please refer the below screen for the output.)


  

The output



Note: This article is based on Smarten Version 5.0. This may or may not be relevant to the Smarten version you may be using.


1 Comment

Answer

Procedure: 

1.   Right click on any cell in that text column.

2.   Select Transform -> Data type. (Refer below pic)


  

                                                    Transforming datatype


3.   Select the data type as TimeStamp.

4.   In the format section, if the 24 hour format is there then input format should be yyyyMMddHHmmss where HH= Hours for 24 hour format. Similarly, for 12 Hours Format, the input format should be yyyyMMddhhmmss where MM is for Month and mm is for minute. 

(Refer below pic)



 

Transforming datatype to 24 Hour format


5.   And click on Apply. (Please refer the below screen for the output.)


  

The output



Note: This article is based on Smarten Version 5.0. This may or may not be relevant to the Smarten version you may be using.


Login to post a comment