10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hello,
We have wrote shell script for multiple file name search pattern.
file format: <numner>_<20180809>.txt
starting with single number and ending with 8 digits number
Command:
awk -v string="12_1234" -v serch="^+_+$" "BEGIN{ if (string ~/serch$/) print string }"
If sting matches... (4 Replies)
Discussion started by: koti_rama
4 Replies
2. Shell Programming and Scripting
I'm interested to match column pattern through awk using an external variable for data:
-9 1:751343:T:A -9 0 T A 0.726 -5.408837e-03 9.576603e-03 7.967536e-01 5.722312e-01
-9 1:751756:T:C -9 0 T C 0.727 -5.360458e-03 9.579447e-03 7.966977e-01 5.757858e-01... (7 Replies)
Discussion started by: genome
7 Replies
3. Shell Programming and Scripting
Input:
|Running the Rsync|Sun Oct 16 22:48:01 BST 2016
|End of the Rsync|Sun Oct 16 22:49:54 BST 2016
|Running the Rsync|Sun Oct 16 22:54:01 BST 2016
|End of the Rsync|Sun Oct 16 22:55:45 BST 2016
|Running the Rsync|Sun Oct 16 23:00:02 BST 2016
|End of the Rsync|Sun Oct 16 23:01:44 BST 2016... (4 Replies)
Discussion started by: busyboy
4 Replies
4. Shell Programming and Scripting
Hi Forum.
I have the following script that I would like to use a variable to search using awk but it's not working as expected:
# Define working variables
token_search_string=536088
token_search_length=16
This code example works by hardcoding 536088 in the string search:
awk -v... (10 Replies)
Discussion started by: pchang
10 Replies
5. Shell Programming and Scripting
consider the script below
sh /opt/hqe/hqapi1-client-5.0.0/bin/hqapi.sh alert list --host=localhost --port=7443 --user=hqadmin --password=hqadmin --secure=true >/tmp/alerts.xml
awk -F'' '{for(i=1;i<=NF;i++){
if($i=="Alert id") {
if(id!="")
if(dt!=""){
cmd="sh someScript.sh... (2 Replies)
Discussion started by: vivek d r
2 Replies
6. Shell Programming and Scripting
Hai,
I need to search a variable inside a file using awk in AIX.
for ex:
file.txt
one
two
three
four
five
i need to get the lines with two
awk '/two/ {print}' file.txt
But i need to change the two as a variable since it would be changed on runtime..i tried like below..nothing give... (3 Replies)
Discussion started by: jesu
3 Replies
7. Web Development
(Above from Apache docs).
On my system, using:
SetEnvIf User-Agent Mozilla IsBad=1
Order allow,deny
Allow from all
Deny from env=IsBad ...I see that environment variable is set (using phpinfo()) but the page is still served. No errors in the Apache logs. (1 Reply)
Discussion started by: gnurob
1 Replies
8. Shell Programming and Scripting
Hi,
I have a generic shell script (runBatchJob.sh) to read files (batchJob) with commands in them and execute the commands by reading the batchJob file as below
./runBatchJob.sh batchJob
batchJob file
$BATCHDIR/execute_procedure.sh
$DATADIR/collectData.sh
$OTHER_ENV_VAR/doSomething.sh
... (10 Replies)
Discussion started by: bOngY
10 Replies
9. Shell Programming and Scripting
For a Script I need to detemine which field of the unix environment variable SHLIB_PATH has the
WALTDB entry.
export SHLIB_PATH=/usr/user5/WALTDB/oracle/product/10.2.0/lib32:/usr/TZD/bin.wdad/mug/oracle/lib:
echo $SHLIB_PATH | awk -F: '{ print $1 }'
Shure gives me the first entry, but... (6 Replies)
Discussion started by: sdohn
6 Replies
10. Shell Programming and Scripting
Hi!
I want to print selected lines from a file using awk.The file contains 6 columns(dates,time,title,description,location and attendees). So i ask the user to insert the date that he wants to display and then search the file for the matching dates so i can print the line.
echo Give the date... (7 Replies)
Discussion started by: DDoS
7 Replies