I am a newbee at unix. I checked out the video for using tabulate to convert a csv file to an html on a tabular format. Trying to do the same a running into issues as below:
both the above commands are giving the below error:
cat: 0652-050 Cannot open /dev/stdin.
I realise stdin refers to the input. is it not able to read the file. i tried giving the whole path as well, still the same. the export.csv has full permissions 0777.
Unable to debug further.
Please suggest.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
if so, then tabulate.sh must be able to read the data on its standard input, through the pipe.
You may also try editing tabulate.sh, search for /dev/stdin and try substititing it with a hyphen character or a character that represents stdin on your unix machine. Also, discuss this with your sysadmin, if possible.
Additionally, a small linux system like puppy linux can do the job as well.
P.S. The latest version of tabulate.sh incorporates hyphen as the data to be read on its standard input.
Hi,
I am a newbee at unix. I checked out the video for using tabulate to convert a csv file to an html on a tabular format. Trying to do the same a running into issues as below:
cat export.csv | ./tabulate.sh -d "," -t "XXX" -h "Validation" > EmailBody.html
db2 -tvmf export.csv | ./tabulate.sh -d "," -t "XXX" -h "Validation" > EmailBody.html
both the above commands are giving the below error:
cat: 0652-050 Cannot open /dev/stdin.
I realise stdin refers to the input. is it not able to read the file. i tried giving the whole path as well, still the same. the export.csv has full permissions 0777.
Unable to debug further.
Please suggest.
Hi,
Does
cat export.csv | cat -
return data on the terminal / console ?
if so, then tabulate.sh must be able to read the data on its standard input, through the pipe.
You may also try editing tabulate.sh, search for /dev/stdin and try substititing it with a hyphen character or a character that represents stdin on your unix machine. Also, discuss this with your sysadmin, if possible.
Additionally, a small linux system like puppy linux can do the job as well.
P.S. The latest version of tabulate.sh incorporates hyphen as the data to be read on its standard input.
Also, for Systems without Bash, but having other shells, Some Unix Systems, Old Systems or Systems where this script fails for some reason, Please use this alternate Script : https://sourceforge.net/projects/command-output-to-html-table2/
Hope this helps.
Last edit: Nathan S.R. 2022-01-18