10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I'm trying to use a series of regular expressions as variables but can't get it to behave properly.
You can see below what I'm trying to do.
Here with lowercase a-z and the same with uppercase, numbers 0-9 and again with a set of special characters, without having to type out every single... (3 Replies)
Discussion started by: 3therk1ll
3 Replies
2. UNIX for Dummies Questions & Answers
Readers,
Reading a previous post about comparing files using awk ('awk-compare-2-columns-2-files-output-whole-line', https://www.unix.com/shell-programming-scripting/168432-awk-compare-2-columns-2-files-output-whole-line.html), it is possible to adjust this, so that regular expression can be used... (8 Replies)
Discussion started by: linuxr
8 Replies
3. UNIX for Dummies Questions & Answers
i have a command line like this in csh script
grep -i "$argv$"
which i wanted to select the line ending with string provided as argument but it couldn't interpret the '$' (ending with)..
any help? (3 Replies)
Discussion started by: ymc1g11
3 Replies
4. Shell Programming and Scripting
Hi All,
I have a sftp session log where I am transferring multi files by issuing "mput abc*.dat". The contents of the logfile is below -
#################################################
Connecting to 10.75.112.194...
Changing to: /home/dasd9x/testing1
sftp> mput abc*.dat
Uploading... (7 Replies)
Discussion started by: k_bijitesh
7 Replies
5. Programming
Hi all,
How am I read a file, find the match regular expression and overwrite to the same files.
open DESTINATION_FILE, "<tmptravl.dat" or die "tmptravl.dat";
open NEW_DESTINATION_FILE, ">new_tmptravl.dat" or die "new_tmptravl.dat";
while (<DESTINATION_FILE>)
{
# print... (1 Reply)
Discussion started by: jessy83
1 Replies
6. Shell Programming and Scripting
Hi,
I need to compare file names in a folder with several strings(which are in regular expression format):
For example:
there is a file "objectMyHistoryBook" and there are several strings to compare this file name with:
objectMyMaths*, objectMyEnglish*, objectMyHistory*,... (2 Replies)
Discussion started by: Lucifer_123
2 Replies
7. Shell Programming and Scripting
Hi,
I'm trying to compare the value in a field to the value in a variable using awk. This works:
awk '$7 == "101"'but this is what I want (and it doesn't work):
value=101
awk '$7 == "$value"'
Any help or insight on this would be great. Thanks in advance. (1 Reply)
Discussion started by: goodbenito
1 Replies
8. Shell Programming and Scripting
Anyone know how I will use awk's variable in a regular expression?
This line of code of mine is working, the value PREMS should be a variable:
awk '$1 ~ /PREMS/ { if(length(appldata)+2 >= length($1)) print $0; }' appldata=$APPLDATA /tmp/file.tmp
The value of APPLDATA variable is PREMS.
... (2 Replies)
Discussion started by: Orbix
2 Replies
9. Shell Programming and Scripting
is it possible? if so, how?
i want to check a variable whether is it a number or letter in an if-else statement (6 Replies)
Discussion started by: finalight
6 Replies
10. Shell Programming and Scripting
hello,
I use AIX with ISM PILOT, I want to match something with a varible like this :
$variable = 10 #this variable is the number of the job
"$variable STARTED" # the pattern
how can use this variable to match it with the word STARTED
Tanks (0 Replies)
Discussion started by: barribar
0 Replies