10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
hi all,
Say i have a range like 0 - 1000 and i need to split into diffrent files the lines which are within a specific fixed sub-range. I can achieve this manually but is not scalable if the range increase.
E.g
cat file1.txt
Response time 2 ms
Response time 15 ms
Response time 101... (12 Replies)
Discussion started by: varu0612
12 Replies
2. Shell Programming and Scripting
Hi
i am in learning phase of unix
i am able to understand basic of awk but not able to understand Pattern-Specific Actions in awk below is the snippet .
awk '
/ *\$*\. */ { print $1,$2,$3,"*"; }
/ *\$0\. */ { print ; }
' fruit_prices.txthere i am not getting the use of wild card. what... (4 Replies)
Discussion started by: scriptor
4 Replies
3. Shell Programming and Scripting
Learning, stumbling! My progress in shell scripting is slow. Now I have this doubt:
I have the following file (users.txt):
AU0909,on
AU0309,off
AU0209,on
AU0109,off
And this file (userson.txt)
AU0909
AU0209
AU0109
AU0309
I just want to set those users on userson.txt to "off" in... (14 Replies)
Discussion started by: quinestor
14 Replies
4. Shell Programming and Scripting
I have been struggling with a script to automate some security related activities. I have it pretty much working, all except the search. I have an input file formatted as such:
216.234.246.158 216.234.246.158 ``
24.249.221.22 24.249.221.200 ``
24.249.226.0 ... (4 Replies)
Discussion started by: tsunami4u
4 Replies
5. Shell Programming and Scripting
Hi, I need to create weekly files from daily records stored in individual monthly filenames from 1999-2010. my sample file structure is like the ones below:
daily record stored per month:
199901.xyz, 199902.xyz, 199903.xyz, 199904.xyz ...199912.xyz
records inside 199901.xyz (original data... (4 Replies)
Discussion started by: ida1215
4 Replies
6. Shell Programming and Scripting
hi !
how can i get files in a directory between certain date ranges ?
say all files created/modified between Jan24 - Jan31
thanks (10 Replies)
Discussion started by: aliyesami
10 Replies
7. Shell Programming and Scripting
Trying to sum field #6 when field #2 matches string as follows:
Input data:
2010-09-18-20.24.44.206117 UOWEXEC db2bp DB2XYZ hostname 1
2010-09-18-20.24.44.206117 UOWWAIT db2bp DB2XYZ hostname ... (3 Replies)
Discussion started by: ux4me
3 Replies
8. Shell Programming and Scripting
I want to check if a zip code is valid, using a variable that stores the zipcode. I am not sure how I would do this in a script. I know that simply checking for the numerical range of the number will not work, because '1' would be '00001' in zip code format. I know when I am in shell, I can use... (5 Replies)
Discussion started by: userix
5 Replies
9. UNIX for Advanced & Expert Users
I cannot seem to get this text file to format. Its as if the awk statement is being treated as a simple cat command.
I manned awk and it was very confusing. I viewed previous posts on this board and I got the same results as with the
the awk command statement shown here. Please help.
... (6 Replies)
Discussion started by: tekline
6 Replies
10. Shell Programming and Scripting
set -A arr a1 a2 a3 a4
# START
ssh -xq $Server1 -l $Username /usr/bin/ksh <<-EOS
integer j=0
for loop in ${arr}
do
printf "array - ${arr}\n"
(( j = j + 1 ))
j=`expr j+1`
done
EOS
# END
=========
this is not giving me correct output.
I... (5 Replies)
Discussion started by: reldb
5 Replies