ExecuteStreamCommand will "Executes an external command on the contents of
a flow file"
Looks like you want to format the output of your ExecuteSQL, instead I
would suggest.

ListDatabaseTables > ExecuteSQL > ReplaceText > {do something else with the
flowfile} > PutHDFS / MergeContent / PutFile


On Tue, Dec 20, 2016 at 6:55 AM Selvam Raman <[email protected]> wrote:

Hi,

My flow like below

listdatabasetables->executesql->streamcommand

streamcommand i am using "ne.sh" script to write the count and tablename.

""""ne.sh"""""
#!/bin/sh
echo $1" : "$2 >> /home/nifi/neurocount.txt
exit 0


the data is written to txt file but always i am getting error as stream
closed.

Exact exception:
write flow file stdin due to -> java.io.exception broken pipe
java.lang.unixprocess ->java.io.exception stream closed

can you please help to solve this.



-- 
Selvam Raman
"லஞ்சம் தவிர்த்து நெஞ்சம் நிமிர்த்து"

Reply via email to