10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
Hello ,
Using the below scrip to search a string in a file , by case-insensitively
Please assist on using the toupper() as getting error !.
#!/usr/bin/ksh
set -x
curr_dir=`pwd`
file_ctr=0
printf "\n Reviewing the output file from the directory: %s \n\n" $curr_dir
ls -latr ... (4 Replies)
Discussion started by: Siva SQL
4 Replies
2. Shell Programming and Scripting
I have a special case that awk could be used but I do not have the skill. Trying to create a final output file (indel_parse.txt) that is created from using some information from each of the two files (attached).
parse rules:
The header is skipped FNR>1
1. 4 zeros after the NC_ (not... (2 Replies)
Discussion started by: cmccabe
2 Replies
3. Shell Programming and Scripting
Hello
I have a file with the following format:
...
text1 num num P
# 2014--2-28-22---6 33.76--38.4173---21.9403----0.08-0.00--0.01--0.01--0.46----------0
text1 num num P
text 2 num num S
text 3 num num P
...
(where "-"=space, "spaces" cannot... (4 Replies)
Discussion started by: phaethon
4 Replies
4. Shell Programming and Scripting
Hi All,
I have a data file (myfile.txt) as below:
- A H C
- A HHH F
- AAA HH I
The importan point is that the width between the columns are not fixed and the column seperator is space.
I wish to change the value of 4th column using awk only when $3 = HH. I can... (4 Replies)
Discussion started by: angshuman
4 Replies
5. Shell Programming and Scripting
here is a statement
awk '/CREATE PROCEDURE/,/elimiter/' "$file1" > onlyproc1.sql
which mean cut from create procedure to Delimiter or delimiter and paste it in onlyproc1.sql... my query is how to make this case insensitive.. that is i want the above code to work whther it is Delimiter or... (26 Replies)
Discussion started by: vivek d r
26 Replies
6. UNIX for Dummies Questions & Answers
the idea is to create script with menu and when option 1 or2 is pressed program should clear screan display info and get back to menu....
I managed some code but getting errors...
#!/bin/bash
choice1=ls -l|awk'{print $9 $1}'
choice2= ls | wc -c
choice3=exit
while
do
clear
echo "... (8 Replies)
Discussion started by: me.
8 Replies
7. Shell Programming and Scripting
Hi All,
How we can perform case-insensitive search with AWK.:rolleyes:
regards,
Sam (11 Replies)
Discussion started by: sam25
11 Replies
8. Shell Programming and Scripting
#!/bin/sh
nowpwd=`pwd`
cd $VAMPIRE_HOME
configFile=$VAMPIRE_CFG/vampire.cfg
inpuFileName=`awk -F\= '{
if ($1 == "PrepFilePos.InpFilePosDepo")
{
printf("%s",$2)
exit 0
}}' < $configFile`
I need to know what the awk doing here and what is the expected result here... (1 Reply)
Discussion started by: habuzahra
1 Replies
9. Shell Programming and Scripting
can I tell awk to be case insensitive for one operation without setting the ignorecase value ?
thanks,
Steffen (7 Replies)
Discussion started by: forever_49ers
7 Replies
10. Shell Programming and Scripting
Is there any way to do case insensitive search with awk for the below statement:
month1=`awk '/month/' ${trgfile} | cut -d"=" -f2`
the "month" could come as Month, mOnth,MONTH etc. in a file.
Now I am looking for "month"....
Thanks,
AC (4 Replies)
Discussion started by: acheepi
4 Replies