Hello all!
I've been working for days on this and it is really bugging me!!
Here's my dilemma:
Say I have a very large text file which contains fields delimited my a ':' which logs various records. Each record is separated by a newline character, therefore I can search for lines with... (6 Replies)
what command can i use to search the files in a directory for a text. the output would list the files containing the text. ive tried this but it is not exactly what im looking to do: find . -name "*.xml" -exec agrep searchstring {} \; (2 Replies)
If I go into a directory and type in ..
more * | grep foo
I get the lines of text that contain foo in all of the files in the directory out of all of the files that are there.
How do I make it so I can find out what the names of the files are that contain that text "foo"? By doing what I... (4 Replies)
Hi
I am trying to search a firewall syslog space delimeted file for all of the different tcp and udp destination ports.
I know that grep will find lines that contain specific text. And I have tried using the the the cut command to cut out of the file certain colums. However the test I am... (6 Replies)
Looking for a bit of help. I need to search for a string of words, but unfortunately these words are located on separate lines.
for example the text output is:
United
Chanmpions
Ronaldo
Liverpool
Losers
Torres
and my script code is
print("DEBUG - checking file message");
while... (15 Replies)
Hi Gurus,
I am new to unix.I have a requirement as below
I have text file like a.txt which contains
a.txt
hi hello
process update
status
Ok to Proceed no issues good
data arrangement
My requirement here is i need to read the file and check for the words
"OK to Proceed" and if... (2 Replies)
Hi
I would love a bit of help with a problem im having with a script. I need to insert a line of text which is saved in a variable called $fwInsert into a file whos name is saved in a variable called $server but it needs to be in a certain order.
The file is a forward file for a network and... (12 Replies)
Hi,
I need help searching through a large text file. I need to find a certain string within the text, and copy each line until another string appears.
The file looks like this:
>scf15164843
ATTAAAGGNNNGGAATTTCCCCAA
ATTACCGGCTTTAAANNNTTACCC
>scf15154847
CCGGGNNNTTTAAACCCGNGNGCC... (2 Replies)
Hi Gurus,
i have 8 zipped files and each file is having more than 100,000 records or more.
issue :-
i want to search the missing text from each zipped files
i have stuck here, the below command works fine if i give the value 10 for the deptno.
if i have more than 1 records... (6 Replies)
I'm trying to get one specific number out of a text file, in order to use as part of an algorithm in a shell script. It will always come after a specific string and that string won't appear anywhere else in the file.
So I'm trying to search through the file for that one string, then grab the... (2 Replies)
Discussion started by: mikedigornio
2 Replies
LEARN ABOUT DEBIAN
regexp
Regexp(3I) InterViews Reference Manual Regexp(3I)NAME
Regexp - regular expression searching
SYNOPSIS
#include <InterViews/regexp.h>
DESCRIPTION
A Regexp encapsulates a regular expression pattern and defines operations for searching and matching the pattern against a string. The
syntax of the regular expression pattern is the same as that for ed(1). Information can be obtained about the most recent match of the
regular expression (and its sub-expressions).
PUBLIC OPERATIONS
Regexp(const char* pattern)
Regexp(const char* pattern, int length)
Construct a new Regexp for pattern.
int Match(const char* text, int length, int index)
Attempt a match against text (of length length) at position index. The return value is the length of the matching string, or a neg-
ative number if the match failed.
int Search(const char* text, int length, int index, int range)
Search for a match in the string text (of length length). Matches are attempted starting at positions between index and index plus
range. If range is positive the first match after index is reported. If range is negative the first match before index is
reported. The return value is the index of the starting position of the match, or a negative number if there is no match in the
specified range.
int BeginningOfMatch(int subexp)
int EndOfMatch(int subexp)
Return information about the most recent match. If subexp is zero (the default), information is reported for the complete regular
expression. Other values of subexp refer to sub-expressions in the pattern. For example, if subexp is 2, information is returned
for the sub-expression specified by the second pair of ( and ) delimiters in the pattern.
SEE ALSO ed(1)InterViews 23 May 1989 Regexp(3I)