10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi ,
I'm trying to list the files and output is written to a file. But when I execute the command , the output file is being listed. How to exclude it ?
/tmp
file1.txt
file2.txt
ls -ltr |grep -v '-' | awk print {$9, $5} > output.txt
cat output.txt
file1.txt
file2.txt
output.txt (8 Replies)
Discussion started by: etldeveloper
8 Replies
2. Shell Programming and Scripting
Hi All,
I am new here but I have a scripting question that I can't seem to figure out with the "find" cmd.
What I am trying to do is to only have to run a single find cmd parsing the directories and output the different file types to induvidual files and I have been running into problems.... (3 Replies)
Discussion started by: swaters
3 Replies
3. Shell Programming and Scripting
Hi all,
I'll like to search a list of tems in a huge file and then output each of the terms to individual files. I know I can use grep -f list main.file to search them but how can I split the output into individual files? Thank you. (6 Replies)
Discussion started by: ivpz
6 Replies
4. Shell Programming and Scripting
Hi All,
I have some data like below.
Step1,Param1,Param2,Param3
1,2,3,4
2,3,4,5
2,4,5,6
3,0,1,2
3,0,0,0
3,2,1,3
........
so on
Where I need to find the median(arithmetic) of each column from Param1...to..Param3 for each set of Step1 values.
(Sort each specific column, if the... (5 Replies)
Discussion started by: ks_reddy
5 Replies
5. Shell Programming and Scripting
Hi,
I have a situation to compare one file, say file1.txt with a set of files in directory.The directory contains more than 100 files.
To be more precise, the requirement is to compare the first field of file1.txt with the first field in all the files in the directory.The files in the... (10 Replies)
Discussion started by: anandek
10 Replies
6. Shell Programming and Scripting
I have an input file with contents like:
MainFile.dat:
12247689|7896|77698080
16768900|hh78|78959390
12247689|7896|77698080
16768900|hh78|78959390
12247689|7896|77698080
16768900|hh78|78959390
12247689|7896|77698080
16768900|hh78|78959390
12247689|7896|77698080
16768900|hh78|78959390
... (4 Replies)
Discussion started by: rkrish
4 Replies
7. Shell Programming and Scripting
Hi All,
I am using the awk command to replace ',' by '\t' (tabs) in a csv file. I would like to apply this to all .csv files in a directory and create .txt files with the tabs.
How would I do this in a script?
I have the following script called "csvtabs":
awk 'BEGIN {
FS... (4 Replies)
Discussion started by: ScKaSx
4 Replies
8. AIX
$ indicates blank space
file1.txt:
001_AHaris$$$$$020$$$$$$$$$
001_ATony$$$$$$030$$$$$$$$$
002_AChris$$$$$090$$$$$$$$$
002_ASmit$$$$$$060$$$$$$$$$
003_AJhon$$$$$$001$$$$$$$$$
$ indicates blank space
code
while read "LINE"; do
echo "$LINE" | cut -c6- >> $(echo "$LINE" | cut... (1 Reply)
Discussion started by: techmoris
1 Replies
9. Shell Programming and Scripting
help trying to figure out a batch shell script to zip each file in a directory into its own zip file
using this code but it does not work
tryed this also
nothing seems to work , just ends without zipping any files
i have over 3000 files i need to zip up individualy
... (7 Replies)
Discussion started by: wingchun22
7 Replies
10. Shell Programming and Scripting
I believe I read somewhere that you can do a diff of two ksh scripts and use the output to create a new script with the differences. :p
Could someone please show me the command(s) I'd need to use to get this accomplished? Or perhaps point me to a thread that explains this in detail.
Thanks... (1 Reply)
Discussion started by: BCarlson
1 Replies