Formatting a datetime referring to a 24-hours clock

pmscorca 877 Reputation points
2024-06-29T10:39:24.92+00:00

Hi,

in an ADF pipeline I'm trying to use this expression:

@formatDateTime(utcNow(),'yyyy-MM-ddTHH:mm:ss')

but this return a value that shows the AM/PM indicator.

I'd like to show the time referring to the 24-hours clock.

Any suggests to me, please? Thanks

Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
9,977 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Thomas Daniel 0 Reputation points
    2024-06-29T10:45:53.5+00:00

    Certainly! To display the time in a 24-hour format without the AM/PM indicator, you can use the following expression: @formatDateTime(utcNow(),'yyyy-MM-ddTHH:mm:ss', 'en-US', 'K') The 'K' format specifier ensures that the time is represented in a 24-hour clock format. Covered CA