Results 1 to 2 of 2
Hi all
Its my first post in here so please be patient
I am trying to use regex in perl script to detect allowed words from the file and then ...
- 10-04-2010 #1Just Joined!
- Join Date
- Oct 2010
- Posts
- 1
[SOLVED] Regex help needed
Hi all
Its my first post in here so please be patient
I am trying to use regex in perl script to detect allowed words from the file and then print output to the screen.
As an example :
I have text file with orders and returns :
Item2-SKU-2-11.08.2010-online
Item3-SKU-3-11.09.2010-return
Item4-SKU-4-11.09.2010-store
My question: is it possible to make sure that i am ony outputing to the screen orders based on few conditions like Item,order form e.g. online.And is it possible to have multiple matches (Item2 only diplay if ordered online etc)
Your help is much appreciated
Thanks
- 10-05-2010 #2Linux User
- Join Date
- Aug 2006
- Posts
- 458
this will print any line with "Item2" and "online" .Code:awk '/Item2/ && /online/' file


