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.
Post here if you experience problems or get unexpected errors.
Trying to write a MySQL Action to Insert normal email contents (subject, body, etc.) but MySQL throws a syntax error on anything that has quotes, single quotes, etc.

Tried changing the MySQL field datatype to LONGBLOB but still having the problem. I know that, somehow, I have to escape the strings prior to sending it to MySQL, but how do I do that from inside Email Parser? I have written the SQL on an Action to insert the row, and on a basic email, it works fine. It's only a problem with emails that contain those types of characters.

What is the best MySQL datatypes to use for storage, and does anyone have a basic example of what the INSERT statement should look like?

Thanks, Tim
Hello Tim,

Thanks for reporting this error. I've fixed Email&Parser MySQL actions to automatically escape all the special characters (including quotes as you mentioned) in the field values.

The fixed version is available in the Download section of this website:

http://www.automatedemailparser.com/download.php


For example, in the following SQL sentence:

INSERT INTO users (`column1`, `column2`) VALUES ('<%name%>','<%email%>')

If name is, for example, Joe o'Connor and email is joe@test.com. Email&Parser will now escape the quote:

INSERT INTO users (`column1`, `column2`) VALUES ('joe o\'Connor ','joe@test.com')
Thanks for posting the fix! Been racking our brains trying to figure this out. Emails that that contain special characters are now getting formatted / escaped properly prior to sending the Insert to MySQL, which allows the row to be written.

Thanks again, we will continue our evaluation and hope to purchase a license soon!

Kind Regards, Tim
Great to know it worked on your side. Thanks for reporting Tom
Same thing is happening for MS SQL database. Any chance you can fix that as well?

Here is my insert statement....

INSERT INTO dropbox
(user_email, user_dropbox, contact_email, email_subject, email_body)
VALUES ('<%From%>', '<%To%>', '<%FromField%>', '<%Subject%>', '<%Body%>')


Here is part of the body of the email....

Subject: Password issues again

Marcia Bloom was not able to log in to the CRM even with forgot password, so I went into Scott's admin to re-set her password.


Here is the error.....

Error. Incorrect syntax near 's'.
'her' is not a recognized SET option.
Unclosed quotation mark after the character string ')'..

Any help would be appriciated.
Yes, this is exactly the problem I am having. In MS SQl, It gives an error because the single qoute ' is not escaped properly by the program. Is this something you can fix? If not, can someone please tell me how to do a find and replace script action on the entire body field replacing all the single quotes with an asterisk * or something. I am really hoping the escaped characters problem can be fixed asap. I really want to buy this software, but hard to believe at version 3.1 already and this is an issue. Thanks
Hello,

Thanks everybody for reporting this problem. We have just fixed this issue on the 3.3 Beta release. You can download it from:

http://www.automatedemailparser.com/Ema ... _setup.msi

Any comments are welcome