Hi 

I have a really simple problem that I could solve easily with a strstr() call 
in c but cannot get my head around in perl.

I have have the following input.

Active Accounted actions on tty57, User fred Priv 1
 Task ID 35176, Network Accounting record, 02:04:00 Elapsed

what I want to do is 

   for $data (@raw_data){
        if $data contains "User"
                $username = [the word after User];
   }

The length of this string can vary so I cannot rely on "User" being at n 
charcters from beginning or end of string.

I am sure it is a RegEx problem but any help/pointers appreciated.

Thanks

Kevin

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to