Search Results

Search: Posts Made By: kemisola
2,442
Posted By kemisola
( awk ' BEGIN {count=0} ...
(
awk '
BEGIN {count=0}
/^&/ {
if (substr ($0,1,2) != "&&") ++count
if (count == 2) exit
}
{print}
' file1

cat file2...
89,317
Posted By kemisola
awk ' { printf $0 while (length ($0)...
awk ' {
printf $0
while (length ($0) && substr ($0, length ($0), 1) != "E") {
getline; printf $0
}
if (length ($0) == 0) print "E"; else print ""
}' infile > outfile
6,711
Posted By kemisola
Could it be that the last line in oraenv.sh ...
Could it be that the last line in oraenv.sh

/usr/local/bin/oraenv

should be

. /usr/local/bin/oraenv

?
5,360
Posted By kemisola
You can do the delete as part of the find...
You can do the delete as part of the find command:

find . -name "*.NEW" -ctime +0 -print -exec rm {} \;

Note that this prints out the name of each file it deletes.
4,321
Posted By kemisola
grep -c -i -h "href" *html */*html *htm *shtml...
grep -c -i -h "href" *html */*html *htm *shtml 2>> /dev/null |\
awk 'BEGIN {t=0} {t+=int($1)} END {printf "%ld\n", t}'
2,259
Posted By kemisola
For this to work you also have to ensure that all...
For this to work you also have to ensure that all single quotes in the data are duplicated. Try this:


sed -e "s/'/''/g" $1 | awk -F"|" '{
printf "insert into table (data_string) values "
...
4,106
Posted By kemisola
find /tough -name temp1 -print -exec awk -F\"...
find /tough -name temp1 -print -exec awk -F\" '/OrderError/{print $2}' {} \;
7
5,081
Posted By kemisola
Using awk IS the something simple! The...
Using awk IS the something simple!

The following awk script parses a file called "data.txt" which contains the data from your example. To modify the number and/or size of the fields just change...
Showing results 1 to 8 of 8

 
All times are GMT -4. The time now is 07:25 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy