Perl Patten Matching and Data Extraction

M

Manasa

The data is in the following format in multiple lines. The method that
I tried seems to be crude way of reading lines. I would really
appreciate if anyone has a better solution or there is some module to
extract data.


Business Name ABCD EFG COMPANY
Business Address ADDRESS LINE1
ADDRESS LINE 2
Zip ZIPCODE
Business Owner BUSINESS OWNER NAME
Mailing Address ADDRESS LINE1
, ADDRESS LINE2
Business Start Date START DATE
Expiration date EXPIRATION DATE
Account# 123456
#Employees 1
#Units 0
#Square Feet 0
Nature of Business ELEC CONSTRUCTION

Business Name HIJ KLMN COMPANY
Business Address ADDRESS LINE1
ADDRESS LINE2
Zip ZIPCODE
Business Owner BUSINESS OWNER NAME
Mailing Address ADDRESS LINE1
, ADDRESS LINE2
Business Start Date START DATE
Expiration date EXPIRATION DATE
Account# 078912
#Employees 1
#Units 0
#Square Feet 0
Nature of Business COMPUTER CONSULT

I need to extract all the field values to store them into a database.
Each record is separated by an empty line.

Thanks in advance,
Manasa
 
M

Mothra

Manasa said:
The data is in the following format in multiple lines. The method that
I tried seems to be crude way of reading lines. I would really
appreciate if anyone has a better solution or there is some module to
extract data.
Can you print the method you tried?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,982
Messages
2,570,185
Members
46,738
Latest member
JinaMacvit

Latest Threads

Top