Plz. help me . I am new to perl I want to accept a pattern from screen and search the pattern in my one or two text data base and print the details
The pattern from screen may consist spaces and special char. line / - etc. I use redhat linux 8.0 I have coded like below but fetched no result code------------------------------------------> system( "echo -en 'Enter Pattern :\c'"); $pat = <STDIN>; open (FILEONE,"file1"); while(<FILEONE>){ if($pat=~$_){print $_;} close(FILEONE); open (FILETWO,"file2"); while(<FILETWO>){ if($pat=~$_){print $_;) close(FILETWO); end of code-----------------------------------> plz. help me thanks in advance manojvajram __________________________________ Do you Yahoo!? Yahoo! Mail is new and improved - Check it out! http://promotions.yahoo.com/new_mail -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>