in reply to print line containing string

It sounds like you are "slurping" the whole file at once. Check the value of $/ (input record separator) when you read in your file.

Replies are listed 'Best First'.
Re^2: print line containing string
by Anonymous Monk on May 06, 2010 at 14:12 UTC
    how do I check the $/ (input record saperator)
      Thank you . The input record saperator advice worked . You are an experienced person. Thank you kindly