Sachith Muhandiram
Sachith Muhandiram

Reputation: 2972

Nifi Updaterecord removes leading zero from a record

When I use UpdateRecord processor for removing some certain integers from a number and add leading 0.

Queued values verify leading 0 is there ,But after the process, I use another Update record processor for adding a new column using previously changed column.

My configurations are as followed.

menu enter image description here

csv reader enter image description here

csv writter enter image description here

In values, this process also replaces leading 0 in original column too. How can I keep this value as its after the processor?

Upvotes: 1

Views: 1107

Answers (1)

Lamanus
Lamanus

Reputation: 13551

Do not infer a schema for your case when you read the CSV. If you did that then the number values will be treated as an integer and it will remove the leading zeros. Try with Use String Fields From Header option.

Upvotes: 4

Related Questions