Skip to main content
AJ121
Bronze ⭐️⭐️⭐️
Jun 21, 2020 3:37 PM UTC
Solved

Convert Integer type value to Date format "yyyy-MM-dd" in NiFi Flow File

Hi,

How can i convert integer value like 20190202 into Date format like 2019-02-02 in the NiFi flowfile content?

hegdemahendra
Gold ⭐️⭐️
Jun 24, 2020 5:08 AM UTC

@AJ121 -

Please try this :
${datestring:toDate("yyyyMMdd","GMT"):format("yyyy-MM-dd")}

Please accept if it helped/solved your problem.

1 reply

hegdemahendra
Gold ⭐️⭐️
Jun 24, 2020 5:08 AM UTC

@AJ121 -

Please try this :
${datestring:toDate("yyyyMMdd","GMT"):format("yyyy-MM-dd")}

Please accept if it helped/solved your problem.

Translate