Archives of Support Questions (Read Only)

This is an archived board for historical reference. Information and links may no longer be available or relevant
Announcements
This board is archived and read-only for historical reference. To ask a new question, please post a new topic on the appropriate active board.

How best to replace all TABs (​\t) by COMMAs (,) in the content of a NiFi flow file?

avatar
New Member
 
1 ACCEPTED SOLUTION

avatar
Master Mentor

@Prabir Guha

You can use the replaceText processor to replace tabs with commas in a text/plain input file.

lets assume my input file's content has the following value:

15259-screen-shot-2017-05-09-at-115146-am.png

I could then configure my replaceText processor to do teh following:

15258-screen-shot-2017-05-09-at-114958-am.png

The Search Value is set to a tab.

The Replacement Value is set to a comma.

The resulting content is:

15260-screen-shot-2017-05-09-at-115249-am.png

Thanks,

Matt

View solution in original post

3 REPLIES 3

avatar
Master Mentor

@Prabir Guha

You can use the replaceText processor to replace tabs with commas in a text/plain input file.

lets assume my input file's content has the following value:

15259-screen-shot-2017-05-09-at-115146-am.png

I could then configure my replaceText processor to do teh following:

15258-screen-shot-2017-05-09-at-114958-am.png

The Search Value is set to a tab.

The Replacement Value is set to a comma.

The resulting content is:

15260-screen-shot-2017-05-09-at-115249-am.png

Thanks,

Matt

avatar
New Member

@Matt Clarke "The Search Value is set to a tab." How should the search value TAB be set? '\t' or 0x09

avatar
Master Mentor

I literally hit the "tab" key on my keyboard.