Computer Problems? Computing.Net has over 1,000,000 posts about all things technology related! Over 90% answered within 24 hours! Click here to start participating now! Also, be sure to check out the New User Guide.
How to use substr function in sh
Name: ravichap Date: December 27, 2004 at 11:24:07 Pacific OS: Unix CPU/Ram: No idea
Comment:
Hi,
I want to use substr function, but it is not working in sh. As per help following command works with bash.
stringZ=123456 echo `expr substr $stringZ 1 2`
Any idea what is the problem. If it won't work, then is there any other alternative of substr ( get few characters from a string ) which can be use in sh, ksh, csh.
Summary: Hi. I was wondering if i could define my own functions to use in C Shell ? My code is getting really repetitive. Also can anyone tell me how to store multiple whitespace in a string ? Everytime i set ...
Summary: Hi, I have a file which has lines as follows. /dev/udb/raw305 /dev/udb/raw306 /dev/udb/raw307 Now i want these lines to be edited as DEVICE '/dev/udb/raw305' $3, DEVICE '/dev/udb/raw306' $3, DEVICE '/...
Summary: How do i read binary files in Unix and as i know that counting the number of records in a file could be done using WC command, but how to use it for counting the number of records inside a binary file...