Time function in Azure Data Factory - Expression Builder

Vivek Komarla Bhaskar 956 Reputation points
2022-08-18T18:14:30.863+00:00

I only need to take the time part from the 'Timestamp type source attribute' and load it into a dedicated SQL pool table (Time datatype column). But I don't find a time function within the expression builder in ADF, is there a way I can do it?

-What did I do? -I took the time part from the source attribute using substring and then tried to load the same into the destination table, when I do the destination table inserted null values as the column at the destination table is set to time datatype.

232558-expression-builder.png232631-mapping.png232584-data-preview.png

Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
11,623 questions
{count} vote

1 answer

Sort by: Most helpful
  1. Nasreen Akter 10,811 Reputation points Volunteer Moderator
    2022-08-18T19:17:37.433+00:00

    Hi @Vivek Komarla Bhaskar ,

    would you please try toTimestamp and toString functions. Thanks!

    toString(toTimestamp(field1, 'yyyy-MM-dd HH:mm:ss'), 'HH:mm:ss')  
    

    232623-image.png


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.