Search Results

Search: Posts Made By: ask.jackal
Forum: Filesystems, Disks and Memory 12-04-2006
8,963
Posted By ask.jackal
awk -F, 'NR==1 {head=$0;next} {...
awk -F, 'NR==1 {head=$0;next}
{ y4[$3]+=$4;y5[$3]+=$5;y6[$3]+=$6}
END {
print head;
print "sales,"y4["sales"],y5["sales"],y6["sales"];
print "IT," y4["IT"],y5["IT"],y6["IT"];
print...
3,010
Posted By ask.jackal
IFS="" for i in `cat ${source_file}` do ...
IFS=""
for i in `cat ${source_file}`
do
echo $i
done

John Arackal
82,102
Posted By ask.jackal
grep -o works on linux. Not sure of the...
grep -o works on linux. Not sure of the Solaris/HP etc.

John Arackal
3,639
Posted By ask.jackal
awk '{print "insert into ba_memo_01...
awk '{print "insert into ba_memo_01 values('627562');"}'

works good for me

John
2,250
Posted By ask.jackal
I think you are looking for "expect" scripts....
I think you are looking for "expect" scripts. expect is a scripting language like shell or perl and you need to install it as a package.

John Arackal
2,490
Posted By ask.jackal
awk '/KEYWORD2/ { if ( prev !~ /KEYWORD1/ ) ...
awk '/KEYWORD2/ { if ( prev !~ /KEYWORD1/ ) {print "Error at " NR}} {prev = $0 }' <sample.txt

John Arackal
16,422
Posted By ask.jackal
awk -F\| 'length($4) == 0 || $4 ~/NULL/ {print...
awk -F\| 'length($4) == 0 || $4 ~/NULL/ {print "4th field is null" }' <file.txt

John Arackal
Forum: Programming 11-21-2006
5,487
Posted By ask.jackal
Are u able to set breakpoints in the shared...
Are u able to set breakpoints in the shared library code? Is the shared library built with "-g" option?

John Arackal
3,445
Posted By ask.jackal
sed 's/...$//g'
sed 's/...$//g'
20,171
Posted By ask.jackal
awk 'BEGIN {sum=0;avg=0;}{sum+=$1} END...
awk 'BEGIN {sum=0;avg=0;}{sum+=$1} END {avg=sum/NR;print sum;print avg}' <data

Assumes no white space/extra lines in the data file. ;-)

John Arackal
4,575
Posted By ask.jackal
Yes in the normal case. If you have not modified...
Yes in the normal case. If you have not modified the variable RS in your awk program, its default value is new line and hence a new record would mean "next line"

John Arackal
4,091
Posted By ask.jackal
y=`cat sortie2 | grep "^[1-9999]"| grep...
y=`cat sortie2 | grep "^[1-9999]"| grep "starting"| awk '{ print $NF}'
1,514
Posted By ask.jackal
uname -a John Arackal
uname -a

John Arackal
2,069
Posted By ask.jackal
Are u invoking any programs in the remote server...
Are u invoking any programs in the remote server thru the script after logging in to the machine? Is the error thrown from the part of the script which is supposed to be execed in the remote server?
Forum: Programming 11-08-2006
4,290
Posted By ask.jackal
I think the only time where you can append a...
I think the only time where you can append a count to the string , is preprocessor time which can be done as

#define s##1
#define s##2

John Arackal
218,851
Posted By ask.jackal
Try chsh ~John Arackal
Try chsh

~John Arackal
Forum: Programming 10-05-2006
9,223
Posted By ask.jackal
make sure that the targets are properly tabbed. ...
make sure that the targets are properly tabbed.

John Arackal
2,234
Posted By ask.jackal
sed '/^$/d' $filename John Arackal
sed '/^$/d' $filename

John Arackal
Forum: Programming 03-06-2006
9,760
Posted By ask.jackal
Use GNU tools like gprof/gcov to analyse ur...
Use GNU tools like gprof/gcov to analyse ur program.

John Arackal
Forum: Programming 03-06-2006
7,421
Posted By ask.jackal
One of the major difference is in the buffer...
One of the major difference is in the buffer handling. For eg: if you use printf() , it may handle the strings ,passed to it, in its own way and flush the buffer on its own decision. Sometimes...
4,766
Posted By ask.jackal
Execute the command top from a different console...
Execute the command top from a different console and see if the compiler is really eating up memory. If it was working earlier , please see if there was any change in the optimiaztion level recently....
Forum: Programming 03-02-2006
5,803
Posted By ask.jackal
Use threads . John Arackal
Use threads .

John Arackal
Forum: Programming 01-19-2006
2,301
Posted By ask.jackal
Once the structure is properly initialised , ...
Once the structure is properly initialised ,

(d.CallFunc)() will dereference to the function to which CallFunc pointer is pointing , and invoke it I guess. Meaning it will work like a normal...
26,001
Posted By ask.jackal
Use the command "fuser $filename" to see the...
Use the command "fuser $filename" to see the processed. lsof is not a default package. In my solaris machine , fuser is in /usr/sbin/.

~Jackal
Showing results 1 to 24 of 24

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