or Windows command line:

U:\>find /?
Searches for a text string in a file or files.

FIND [/V] [/C] [/N] [/I] [/OFF[LINE]] "string" [[drive:][path]filename[ ...]]

  /V         Displays all lines NOT containing the specified string.
  /C         Displays only the count of lines containing the string.
  /N         Displays line numbers with the displayed lines.
  /I         Ignores the case of characters when searching for the string.
  /OFF[LINE] Do not skip files with offline attribute set.
  "string"   Specifies the text string to find.
  [drive:][path]filename
             Specifies a file or files to search.

If a path is not specified, FIND searches the text typed at the prompt
or piped from another command.

-----Original Message-----
From: Roger Seielstad [mailto:[EMAIL PROTECTED]
Sent: Friday, January 23, 2004 2:46 PM
To: '[EMAIL PROTECTED]'
Subject: RE: [ActiveDir] Parse CSV with script?


Do a search for a DOS version of grep - that's exactly what you're looking
for my fiend...

You'd do something like
        grep error *.tmp
Spits out just the lines with error in them..

--------------------------------------------------------------
Roger D. Seielstad - MTS MCSE MS-MVP
Sr. Systems Administrator
Inovis Inc.


> -----Original Message-----
> From: Charlie Kaiser [mailto:[EMAIL PROTECTED] 
> Sent: Friday, January 23, 2004 3:41 PM
> To: ([EMAIL PROTECTED])
> Subject: [ActiveDir] Parse CSV with script?
> 
> 
> I'm sure this is probably pretty simple to do, but being a 
> script newbie, I
> don't really know where to look to find what I need.
> I'm running dumpevt against my critical servers via a batch 
> file. Each run
> drops the logs into a separate folder for the server onto my 
> admin machine .
> So what I end up with is a series of folders with 3 .tmp 
> files. I usually
> open them in UltraEdit and read through them each morning. I 
> like dumpevt
> since I can easily look at just the logs since the last check.
> Here's what I'd like to do. I'd like to be able to run a 
> script against the
> .tmp files that would provide me only the lines with criteria 
> that I want to
> see, like "error", "warning", or "failure audit". Or maybe a source
> criteria, like "w32tm" or "netlogon". 
> Does this make sense? Is it possible? Again, I'm not great 
> with scripting
> yet, so I don't really know how to write this from scratch. 
> Can anyone point
> me to a resource with a sample or better?
> Thanks!
> 
> **********************
> Charlie Kaiser
> MCSE, CCNA
> Systems Engineer
> Essex Credit / Brickwalk
> 510 985 0975 x5083
> ********************** 
> List info   : http://www.activedir.org/mail_list.htm
> List FAQ    : http://www.activedir.org/list_faq.htm
> List archive: 
> http://www.mail-archive.com/activedir%> 40mail.activedir.org/
> 
List info   : http://www.activedir.org/mail_list.htm
List FAQ    : http://www.activedir.org/list_faq.htm
List archive: http://www.mail-archive.com/activedir%40mail.activedir.org/


List info   : http://www.activedir.org/mail_list.htm
List FAQ    : http://www.activedir.org/list_faq.htm
List archive: http://www.mail-archive.com/activedir%40mail.activedir.org/

Reply via email to