Search Results

Search: Posts Made By: Cludgie
1,767
Posted By derekludwig
You are not going to get away from some sort of...
You are not going to get away from some sort of loop:
ls -1 | xargs mv -I {} mv {} boxname_{}or
for file in *; do mv $file boxname_$file; donenow if you can save the files for each system in a...
3,352
Posted By Scrutinizer
Try: grep "^$TAC," tacDB.txt or try awk: ...
Try:
grep "^$TAC," tacDB.txt

or try awk:
awk 'NR==FNR{A[$1]; next} $1 in A{print $1,$0}' FS=, OFS=, tacs.tmp tacDB.txt > taclookup.csv
1,200
Posted By cjcox
Assuming input is tab delimited (which I believe...
Assuming input is tab delimited (which I believe it is) and if you have a fear of awk :-)


sed -e 1d -e 's/[ ][ ]*/,/g' -e 's/,/","/g' -e 's/"//' -e 's/$/"/' <imeisvstep1.tmp


The...
1,200
Posted By Scrutinizer
Like so? awk '{for(i=2; i<=NF; i++) $i="\"" $i...
Like so?
awk '{for(i=2; i<=NF; i++) $i="\"" $i "\""}NR>1' FS='\t' OFS=, file
1,986
Posted By Corona688
-x does not make sense for your requirement, it...
-x does not make sense for your requirement, it matches entire lines. Try -w.
1,986
Posted By RudiC
Stop the match at the end-of-line (indicated by...
Stop the match at the end-of-line (indicated by the $-sign following $tariff): while read tariff; do echo $tariff $(grep -c $tariff\$ customer_tariff_list.csv); done <uniq-tariff-addon.csvThere's...
1,986
Posted By RudiC
Try while read tariff; do echo $tariff $(grep -c...
Try while read tariff; do echo $tariff $(grep -c $tariff\" file1); done <file2
T0001 1
T0001-A0001 1
T0001-A0002 0
T0002 1
T0002-A0001 0
T0002-A0002 0
Showing results 1 to 7 of 7

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