10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi all,
I tried searching the forum for this, and I read numerous suggestions here and even on other forums, and I cannot get this to want the way that I need it to. I tried grep -W / -f to no luck. Here is what I have. I have a list of file names-
FILE1-FILE1TEST,FILE1RELATION... (7 Replies)
Discussion started by: jeffs42885
7 Replies
2. Shell Programming and Scripting
Hello!
I have a sample code in which a grep is being performed from multiple files with a date format in their naming convention. Here the script:
#! /usr/bin/bash
cd /IN/service_packages/SMS/cdr/received
MYDATE=`date +"%Y%m%d%H%M"`
#get the value then divide by 60
#DAPS_SLC01... (3 Replies)
Discussion started by: nms
3 Replies
3. Shell Programming and Scripting
Hi ,
I am executing 2 queries and output is saved in file1.txt and file2.txt
example of file1.txt
Testing word Doc.docx,/Lab/Development and Validation/Multitest/MT_010708/Testing,Development and Validation,root,11-Mar-2014,,,,,
Testing Excel _.xlsx,/Lab/Development and... (3 Replies)
Discussion started by: Sunil Mathapati
3 Replies
4. Shell Programming and Scripting
Hi All,
This is the first time I have posted to this forum so please bear with me. Thanks also advance for any help or guidance.
For a project I need to do the following.
1. There are multiple files in multiple locations so I need to find them and the location. So I had planned to use... (9 Replies)
Discussion started by: Charlie6742
9 Replies
5. UNIX for Dummies Questions & Answers
Hi all,
I am still learning my way around unix commands and I have the following question.
I have a website and I want to search for all the html pages that don't contain a certain js file. The file I am searching for is located under /topfolder/js/rules.js . So I assume in my grep search I... (5 Replies)
Discussion started by: SyphaX
5 Replies
6. Shell Programming and Scripting
Hi All,
Please tell me how can I Find a string using grep & print the line above or below that in solaris?
Please share as I am unable to use grep -A or grep -B as it is not working on Solaris. (10 Replies)
Discussion started by: Zaib
10 Replies
7. Shell Programming and Scripting
Hi all,
I want to display line number for matching string in a file. can anyone please help me.
I used
grep -n "ABC" file
so it displays
6 ABC.
But i only want to have line number,i don't want that it should prefix matching context with line number.
Actually my original... (10 Replies)
Discussion started by: sarbjit
10 Replies
8. UNIX for Dummies Questions & Answers
I have a file that looks like this:
Name=TOM
abcded
asdfas
fkoiaerj
inadhah
Name=Chris
23nafds
vasdkfna
afadns
afdadsfa
aaaaaa
bbbbbb
cccccc
I would to search for the string 'bbbbbb', then I would like to search above that string for the 1st occurrence of "Name" and not the other... (7 Replies)
Discussion started by: doza22
7 Replies
9. Shell Programming and Scripting
hi,
i have to grep for string in file but i want to find the group of this line so i must get lines before and select the group.
the file look like :
####name_groupe1
alphanumeric line
alphanumeric line
..
####name_groupe2
alphanumeric line
alphanumeric line
..
####name_groupe3... (4 Replies)
Discussion started by: kamel.seg
4 Replies
10. Shell Programming and Scripting
Hello all
Im performing find + grep operation that looks like this :
find . -name "*.dsp" | xargs grep -on Project.lib | grep -v ':0'
and I like to add to this one liner the possibility to replace the string " Project.lib" that found ( more then once in file ) with "Example.lib"
how can I do... (0 Replies)
Discussion started by: umen
0 Replies