develooper Front page | perl.beginners | Postings from March 2002

Regex Help

Thread Next
March 12, 2002 07:41
Regex Help
Message ID:
Here is snippet of data:

'BRANCH      ':'Kurt':'Strothenke'
'BRANCH      ':'Michael':'Mulligan'
'BRANCH_SSC  ':'Kevin':'Oaks'
'BRANCH_SSC  ':'Thomas':'Grove'
'BRANCH_SSC  ':'Stephen':'Orban'
'BRANCH_SSC  ':'Gerald':'Parnell'
'BRANCH_SSC  ':'Liane':'Mcintyre'
'BRANCHADMIN ':'Ann':'White'
'BRANCHADMIN ':'Brent':'Uhl'

2 problems:

1.  I want to remove the tickmarks from fields 1,2,3 and 
put the data into an array using the : as a separator.  
I am having trouble getting rid of the tick marks, 
everything else works fine.

2.  I want to match whole words only.  I don't want to 
BRANCH to match on BRANCH_SSC or BRANCHADMIN.  My code 
currently matches BRANCH with all three. 

Thanks for your help

Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About