Created 06-20-2019 11:20 AM
Hi!
I need to execute following awk command on flow file via ExecuteStreamCommand processor
awk -F"," '{OFS=","; $4=substr($4,1,19); print $0}'
When run it throws an error: Executable command awk ended in an error: awk: fatal: cannot open file `print $0}" for reading (No such file or directory).
Flow file comes from ListFTP -> FetchFTP -> ExecuteStreamCommand
Could you please help to solve this issue!!
Thank you!!
When running the same awk command on server it works fine:
awk -F"," '{OFS=","; $4=substr($4,1,19); print $0}' myfile.csv
Created 06-20-2019 01:28 PM
At least one problem i see in your config which is causing the following error:
Executable command awk ended in an error: awk: fatal: cannot open file `print $0}" for reading (No such file or directory
Thsis is because in your . "Command Arguments" you are using semicolon. And in "ExecuteStreamCommand" the "Argument Delimiter" is also set to ";" (which is default delimiter)
May be you can try changing the "Argument Delimiter" to something else then check if you are still getting the same error or not?
Created 06-20-2019 01:28 PM
At least one problem i see in your config which is causing the following error:
Executable command awk ended in an error: awk: fatal: cannot open file `print $0}" for reading (No such file or directory
Thsis is because in your . "Command Arguments" you are using semicolon. And in "ExecuteStreamCommand" the "Argument Delimiter" is also set to ";" (which is default delimiter)
May be you can try changing the "Argument Delimiter" to something else then check if you are still getting the same error or not?