Support Questions
Find answers, ask questions, and share your expertise

Split a flowfile by space character

New Contributor

I am wanted to split this txt file into separate flow files at the spaces.


I am very new to nifi and regex and am unsure of which processor and properties I will need.

 

For example:

 

srcip=10.10.10.10 timestamp=152532431 action="denied" logver=12 tz="UTC+0" logid="0000012" dstip=12.12.12.12

This snippet is part of a long line that I need to split up at the spaces

So here I would have 6 separate flow files.

 

Any help appreciated.

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Split a flowfile by space character

Master Guru

@JamesE 

This is easy enough do using the splitContent processor:

Screen Shot 2020-01-17 at 4.33.56 PM.png

for the "Byte Sequence" property simply hit your spacebar to set a single space.

If you found this answer addressed your question, please take a moment to accept to resolve this thread.

 

Hope this helps,

Matt

View solution in original post

1 REPLY 1

Re: Split a flowfile by space character

Master Guru

@JamesE 

This is easy enough do using the splitContent processor:

Screen Shot 2020-01-17 at 4.33.56 PM.png

for the "Byte Sequence" property simply hit your spacebar to set a single space.

If you found this answer addressed your question, please take a moment to accept to resolve this thread.

 

Hope this helps,

Matt

View solution in original post