Search Results

Search: Posts Made By: rajsharma
11,342
Posted By birei
Hi, A solution using Perl: $ cat infile...
Hi,

A solution using Perl:

$ cat infile
"hi","there","how","are","you?","It","was","great","working","with","you.","hope","to","work","y ou."
$ perl -ne 's/,/++$i % 5 ? "," : "\n"/ge; print'...
Forum: AIX 12-13-2010
9,123
Posted By pludi
The read command in KSH has a switch to define a...
The read command in KSH has a switch to define a timeout (-t). Example usage:
echo "Input (timeout 10 seconds):"
read -t 10 userinput
if [ $? -ne 0 ]
then
echo "Using default value"
else
...
Forum: AIX 12-13-2010
9,123
Posted By vgersh99
use #!/bin/ksh93 instead of #!/bin/ksh
use #!/bin/ksh93 instead of #!/bin/ksh
Forum: AIX 12-09-2010
3,412
Posted By
#!/bin/ksh xargs -n2 < file1.txt | while...
#!/bin/ksh

xargs -n2 < file1.txt | while read line
do
set `echo $line | awk -F" " '{print $1 $3}'`
new=$1 ; full=$2
diff=$((full - new))
echo "Diff=$diff"
done
...
Forum: AIX 12-09-2010
3,412
Posted By malcomex999
You can give a try to the above Awk script i...
You can give a try to the above Awk script i posted!!!;)
6,623
Posted By ygemici
because this syntax has differ the meaning: ...
because this syntax has differ the meaning:

\( pattern \) --> save to buffer (mem) matched string(s) or portions with our pattern
\1 --> we can use it when we want to print only this mathced...
6,623
Posted By Corona688
sed doesn't have to use / as the seperator, it...
sed doesn't have to use / as the seperator, it can use most non-special characers. s/day/night/ could also be done as s#day#night#. This is especially convenient when doing things like paths that'd...
6,623
Posted By pludi
sed -n -e 's_.*>\(.*\)<.*_\1_p' filename.xml ...
sed -n -e 's_.*>\(.*\)<.*_\1_p' filename.xml

Brown: Go through the file, but don't print anything by default
Red: The following regex is a substitution
Blue:Look for any text on a line...
Forum: AIX 06-09-2010
2,162
Posted By zaxxon
Best is to have a system you can play around with...
Best is to have a system you can play around with so you can't harm any production system and check out the links here:
https://www.unix.com/aix/17945-aix-links.html

There is a link to the IBM...
Showing results 1 to 9 of 9

 
All times are GMT -4. The time now is 05:54 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy