I've been having trouble trying to read an ASCII file. I'm on an IRIX machine, by the way. I've tried "cat" and I get a bunch of unreadable text, and the "string" command gets the "Command not Found" error. Please advise.
What does unreadable mean? There is no guarantee that ascii files are intelligible. If I use an editor to put these lines:
in a file, all that "cat" can do is display what I typed. Suppose that I call that file "UnderstandingImmanuelKant" and send it to you. You still will only see those three lines of garbage. That is simply all that is in the file.
And maybe you are wrong in thinking that the file is an ascii file? What makes you think that it is?
Anyway the "strings" command (not string) can pull ascii strings out of a binary file.
There is also a "od" command that can show the value of the bytes. And a "more" command that might be useful.
Hi Team,
I am having 100 EBCDIC files (i.e. DAT extension) and need to convert them into ASCII File by unix shell script.
I tried with DD Command but its not providing output as expected.
Sample Text:
------------------
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
Expected Output:... (2 Replies)
Hi All,
I have an ascii file in which few columns are having hex values which i need to convert into ascii. Kindly suggest me what command can be used in unix shell scripting?
Thanks in Advance (2 Replies)
Hi Folks,
While transferring file from FTP software like Filezilla the files gets corrupted.
Is there any way I can check if the recently transferred file is in ASCII and not corrupted. I have tried using file -i filename command which does tell if the file character set is ASCII or binary... (6 Replies)
Hello all,
To give you all a little bit of background. We recently migrated from HP-UX to Redhat Linux and one of the command I used to run on HP-UX to convert an EBCDIC file to ASCII file isn't working on Linux. The code is as follow:
cat workout2.dat | dd cbs=250 conv=block conv=ascii... (3 Replies)
I have a file in below format(ISO ) and to be convert to readable (.txt/Ascii) format .send me the commands/code please
sample as follows
2043010101167157001190002010011120000000002144300000000000000000000 01022_ - %rE@
U...ug 47 56 d %rE@ 01022_ - $5
fy ... (1 Reply)
Hi gurus,
I have a file in unix with ascii values. I need to convert all the ascii values in the file to ascii characters. File contains nearly 20000 records with ascii values. (10 Replies)
Hello All,
I need to read the data inside one file who's format is ascii text. I got the file format when I use file command on the file.
file <filename>
filename ascii text
please help me on this.
Thanks (8 Replies)
I want to verify the file is Binary or ascii file and accordingly I want to switch the program with ret code
ie 0 or success and 1 for failure
Can any one help me is this a correct syntex...i am getting error
#!/bin/ksh
$file filename
if
echo "ascii fie Found"
else
echo " binary... (6 Replies)
I'm writing a script that takes a filename as an argument, which determines the "file type" of the file. I want to know if there is any command I can use to determine if a file is ASCII type, thanks all for giving a help. (11 Replies)