Visit Our UNIX and Linux User Community

Search Results

Search: Posts Made By: vivekshankar
2,584
Posted By vivekshankar
file handling problem in perl......
Hi,
I am opening a file......then i am wrting some data into it......and i am reopening the file again but ......i get a error cannot open file.......

$::file= "\adder\testfile.txt"...
1,249
Posted By vivekshankar
THANKS :-) Regards Vivek.S
THANKS :-)

Regards
Vivek.S
2,095
Posted By vivekshankar
stripping last lien off a file
Hi,
how can i strip the last line off my file using shell script?

Thanks and Regards
Vivek.S
1,639
Posted By vivekshankar
HI , The followingg piece of code prints...
HI ,

The followingg piece of code prints the value....how can i assign it a variable?


#!/usr/bin/perl
$line[1] = "abc dee eeee ggg";
$line[2] = "sd dsd sdsd sdsd sdsd";
$line[3] =...
1,639
Posted By vivekshankar
Thanks a lot!!!! Regards Vivek.S
Thanks a lot!!!!

Regards
Vivek.S
1,249
Posted By vivekshankar
sed question
hi

i have 3 lines like this.......

jjjj | jjjj |jjjjj
sadasd |sadasd |sadasd
dddd | sd|sdd

how can i remove the spaces?


Thanks and Regards
Vivek.S
1,639
Posted By vivekshankar
Thanks for the tutorial seems pretty cool!! :-) ...
Thanks for the tutorial seems pretty cool!! :-)
i tried ggogling and got this cool link too

http://www.cs.cf.ac.uk/Dave/PERL/node95.html

thanks and regards
Vivek.S
1,639
Posted By vivekshankar
perl question
hi,
i have 3 lines of text

abc dee eeee ggg
sd dsd sdsd sdsd sdsd
sdsds sds sdd sdsd sdsd sdsd sdsd

how can i get the last word in each line using perl?

Thanks and...
12,864
Posted By vivekshankar
list read only files using find
hi,
how can i list read only files (for u,g,o) using find command?

Thanks and Regards
Vivek.s
1,392
Posted By vivekshankar
basic perl question
Hi,
I was jus goin through a ebook on perl....it says u get binary installation for both unix and windows.....doesnt perl come already bundeled with unix ?cause i never installed any perl...
4,612
Posted By vivekshankar
Hi sorry bob :-) i was actually workin on a...
Hi

sorry bob :-) i was actually workin on a different unix pc and i am typing mails from a windows pc.......so lots of typos.....

this is my code......

read startdt
ls -l...
1,553
Posted By vivekshankar
Thanks :-) can u tell me the author of the...
Thanks :-)

can u tell me the author of the books.......so that i cud get one...

thanks and regards
vivek.s
4,612
Posted By vivekshankar
hi, i used the foll method to compare ...
hi,
i used the foll method to compare

read startdt

$a = `echo ls -l | cut 44-52` (this returns jus a single line cause i am reading line by line)

if $a-ge$startdt then
echo "hello"...
2,163
Posted By vivekshankar
whew !! cool!! u solve all my problems using awk...
whew !! cool!! u solve all my problems using awk :-) but i havnt implemented any of them cause.....i have to learn awk b4 putiing ur code into use.....i guess that way i cud learn more :-) ( but i am...
2,163
Posted By vivekshankar
hi! ls -1t /some/dir | grep "^a" list the...
hi!

ls -1t /some/dir | grep "^a" list the file names alone....how cud i se the attrbutes liek file size etc?


Thnaks and Regards
vivek.s
2,163
Posted By vivekshankar
hi! but bob, ls -1t /some/dir | grep "^a" ...
hi!
but bob,
ls -1t /some/dir | grep "^a"

doesnt seem to work......cause ls -l list al the parameters like
-x--x--x-- XXXX XXXX abc.sh

it displays other parameters appart from...
4,612
Posted By vivekshankar
oh thats me :-) well i jus wante dto know id...
oh thats me :-)

well i jus wante dto know id there are any pre defined functions that might do the job :-)

Thanks and Regards
Vivek.S
2,163
Posted By vivekshankar
Thanks BOb! Regards Vivek.S
Thanks BOb!

Regards
Vivek.S
4,612
Posted By vivekshankar
thanks......but what is meant by "op" ? ...
thanks......but what is meant by "op" ?


Thanks and Regards
Vivek.S
2,163
Posted By vivekshankar
problem with grep
Hi,
i can list all files starting from a using ltr a*..........but is thereany way usng grep? like.....ls -ltr | grep.......?shud i maybe cut the specific filnema coulmn and redirect to...
5,818
Posted By vivekshankar
Thank you guys!! :-) I will check...was...
Thank you guys!! :-)

I will check...was struggling to get the last field......i guess i have learn awk , till now i dun have any idea abt awk...so b4 goin along with this code i guess it wud be...
4,612
Posted By vivekshankar
thanx, i checked it and got one solution ...
thanx, i checked it and got one solution

a=`date "+%Y%m%d%H%M%S"`
echo $a
sleep 10
b=`date "+%Y%m%d%H%M%S"`
echo $b

if test $b -gt $a
then
echo "$b is greater than $a"
else
echo "$a is...
4,612
Posted By vivekshankar
Date Compare
Hi,
Is there any date compare functionality in unix?

thanks and regards
vivek.s
5,818
Posted By vivekshankar
facing problem with cut command
hi ,
i used ls -ltr | cut -f 1 > \dev\tty

but all teh coulmns r getting printed instead of only one........how can i resolve this?


prob 2 :
wud be able start cutting from last...
8,425
Posted By vivekshankar
Thanks a lot!! :-) Regards Vivek.S
Thanks a lot!! :-)


Regards
Vivek.S
Showing results 1 to 25 of 69

 

Featured Tech Videos

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