email parsing automation

Email Parser

Extract data from emails and automate your workflow

The forum is now read only. Please, go to the the main Email Parser website if you need help.
Need help configuring the program? Have any questions regarding its use?
Hi

I am new to your software, but I must say first impressions are really good.

I hope someone can help me with my problem.

I receive a lot of emails that contain grids on them and the information I need is stored in the grids(the layout format is always the same).It may contain several lines of information within the email(see example) I have not been able to find a way to parse this information into a excel spread sheet, could you tell me if this is possible with your software, as this would save me a lot of time.
I have uploaded an example of the grids I am talking about.
Example1.jpg
Example
Hope someone can help
Thanks
Hi,

Yes, it is possible. But to give you some clues about how to do it I would need a bit more information.

Are the number of columns always the same?

I guess the table is in the email body, not in an attached file. am I right?


If possible, could you send me one of those emails to support@automatedemailparser.com? If you send it as an attached .eml file, the better. To get this file, you have to go to the Email&Parser history, click on the email and select "save email"

Probably, you will need to set up a regular expression parser that parses the HTML version of the email. One field for each column and activate "this field can appear multiple times" in each field.
Thanks for quick reply, I have emailed you the file.
Ok. Thanks for the .eml file.

I have created a small config file to show you how it is done. You can find it attached to this forum post. To load it simply drag and drop the file on the Email&Parser left panel.

The most difficult part is to create a parser able to capture each column. I have used the following regular expression, which may look unreadable unless you know what they are:
Worker\s*(?'worker_name'.*?)\s*\**(\s*\r\n\s*)+(?'Thu'.*?)\*+(\s*\r\n\s*)+(?'Fri'.*?)\*+(\s*\r\n\s*)+(?'Sat'.*?)\*+(\s*\r\n\s*)+(?'Sun'.*?)\*+(\s*\r\n\s*)+(?'Mon'.*?)\*+(\s*\r\n\s*)+(?'Tue'.*?)\*+(\s*\r\n\s*)+(?'Wed'.*?)\*+(\s*\r\n\s*)+(?'Thu2'.*?)\*+
It captures the required fields from following text. It is your email body converted to plain text. Email&Parser do this conversion automatically. The format is lost in the conversion but the data we want to capture is kept.
Please complete the YELLOW parts and return every Tuesday****

** **

Period****

9****

Week****

2****

Workers Name****

Thu****

Fri****

Sat****

Sun****

Mon****

Tue****

Wed****

Thu****

Worker 1****

7-4****

6-3 ****

OFF****

OFF****

11-8****

7-4****

11-8****

9-6****

Worker 2****

11-8****

7-4****

11-8****

9-6****

OFF****

11-8****

OFF****

11-8 ****

Worker 3****

6-3****

OFF****

11-8****

7-4****

11-8****

9-6****

7-4****

6-3****

Worker 4****

OFF****

11-8****

7-4****

11-8****

9-6****

OFF****

6-3****

7-4****

** **
Disclaimer: For the people that want to deal with regular expressions it is highly recommended to use a tool called Expresso (free):

http://www.ultrapico.com/Expresso.htm

More info:

http://www.automatedemailparser.com/d/e ... parsers-23
Attachments
field_thu.jpg
automated_parser_left_panel.jpg
automated_parser_left_panel.jpg (24.74KiB)Viewed 5925 times
(313.35KiB)Downloaded 722 times
Thanks for your help But I cannot get this to work it always says "No coincidences have been found for the field " for every line
I have found why it is not working, your converted email that is converted into text contains **** at the end of each line, my converted email when converted to text does not have these asterisk`s at the end of each line
Any ideas why ?
I am not sure. Sometimes the format is changed when the email is forwarded but this is not the case.

Try this regular expression instead. It will capture the data without the asterisks:
Worker\s*(?'worker_name'.*?)(\s*\r\n\s*)+(?'Thu'.*?)(\s*\r\n\s*)+(?'Fri'.*?)(\s*\r\n\s*)+(?'Sat'.*?)(\s*\r\n\s*)+(?'Sun'.*?)(\s*\r\n\s*)+(?'Mon'.*?)(\s*\r\n\s*)+(?'Tue'.*?)(\s*\r\n\s*)+(?'Wed'.*?)(\s*\r\n\s*)+(?'Thu2'.*?)(\s*\r\n\s*)+
For reference I paste here the same data without the asterisks:

Period

9

Week

2

Workers Name

Thu

Fri

Sat

Sun

Mon

Tue

Wed

Thu

Worker 1

7-4

6-3

OFF

OFF

11-8

7-4

11-8

9-6