05-16-2019
You are getting error since toupper() should be used inside awk. Why do you use toupper() ? (You are already fetching filenames in upper or lower case)
Quote:
for SQLOutFile in `ls $cur_dir *[Aa][Ww]*[Ss][Rr]*[Dd][Mm][Ll]*.lst`;
10 More Discussions You Might Find Interesting
1. 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
2. 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
3. Shell Programming and Scripting
Hey , i am trying to do a search for the certain books , and im trying to make it case insensitive. what i have come up with so far is this :
Database.txt
RETARDED MONKEY:RACHEAL ABRAHAML:30:30:20
GOLD:FATIN:23.20:12:3
STUPID:JERLYN:20:40:3
echo -n "Title: "
read Title
echo -n... (3 Replies)
Discussion started by: gregarion
3 Replies
4. UNIX for Dummies Questions & Answers
Hello,
How do I set case insensitive search mode while the file is open with more command ?
(I know -i option which could be used before opening)
thanks
Vilius (2 Replies)
Discussion started by: vilius
2 Replies
5. AIX
Hello,
Linux man command search is case insensitive by default, but not AIX man.
How do I serch case insensitive while using AIX manual pages ?
thanks
Vilius (7 Replies)
Discussion started by: vilius
7 Replies
6. UNIX for Dummies Questions & Answers
Hi,
I have a file named "test_file" that has the below content. It has words in upper/lower cases
PRODOPS
prodOPS
ProdOps
PRODops
escalate
Shell
My requirement is to replace all the "prodops" (what ever case it may be) with "productionoperations".
I tried using the "i" option with... (7 Replies)
Discussion started by: sbhuvana20
7 Replies
7. UNIX for Dummies Questions & Answers
I am using HP-Unix B.11.31.
Question: How to do the case insensitive search using FIND?
Example: I would like list the files with extension of *.SQL & *.sql.
When I try with command find . -type f -name *.sql, it does not lists file with *.SQL. (5 Replies)
Discussion started by: Siva SQL
5 Replies
8. 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
9. UNIX for Dummies Questions & Answers
Hi All,
What is the command to search a file for a case-insensitive match
1.grep -nc text filename
2.grep -i text filename
3.grep -i filename text
4.grep -nc filename text
5.grep -c text filename
Thanks for your help (1 Reply)
Discussion started by: bobby1015
1 Replies
10. Shell Programming and Scripting
I am trying to find case insensitive file names and then replace that particular file with other name.
if
then
ls | grep -i "update" | xargs -I {} mv {} LineItems.csv
echo "File moved from *update*"
elif
then
ls | grep -i "priority" | xargs -I {} mv {} ... (1 Reply)
Discussion started by: ATWC
1 Replies
LEARN ABOUT OSX
toupper_l
TOUPPER(3) BSD Library Functions Manual TOUPPER(3)
NAME
toupper, toupper_l -- lower case to upper case letter conversion
LIBRARY
Standard C Library (libc, -lc)
SYNOPSIS
#include <ctype.h>
int
toupper(int c);
#include <ctype.h>
#include <xlocale.h>
int
toupper_l(int c, locale_t loc);
DESCRIPTION
The toupper() function converts a lower-case letter to the corresponding upper-case letter. For single C chars locales (see multibyte(3)),
the value of the argument is representable as an unsigned char or the value of EOF.
Although the toupper() function uses the current locale, the toupper_l() function may be passed a locale directly. See xlocale(3) for more
information.
RETURN VALUES
If the argument is a lower-case letter, the toupper() function returns the corresponding upper-case letter if there is one; otherwise, the
argument is returned unchanged.
COMPATIBILITY
The 4.4BSD extension of accepting arguments outside of the range of the unsigned char type in locales with large character sets is considered
obsolete and may not be supported in future releases. The towupper() function should be used instead.
SEE ALSO
ctype(3), isupper(3), multibyte(3), towupper(3), xlocale(3)
STANDARDS
The toupper() function conforms to ISO/IEC 9899:1990 (``ISO C90'').
BSD
August 21, 2004 BSD