2

We have email-to-case set up for our org and we're getting this email:

Subject: Email-to-Case: Error(s) encountered while processing
The following errors were encountered while processing an incoming email:
STRING_TOO_LONG : To Address: data value too large: [multiple emails with a length of 121 characters]

We can't figure out which field is the issue

  • we've tried looking on both the Case object and EmailMessage object.
  • There is no 'To Address' field on Case.
  • The ToAddress field on Email Message has a limit of 4000, so that doesn't seem to be it.

Any ideas would be so appreciated!

1
  • 2
    are you using a custom email handler or SF Email-to-Case? Is there any custom logic on either the EmailMessage or the Case object?
    – Henk3000
    Dec 22, 2021 at 13:27

1 Answer 1

1

The reason you don't see it in the Case is because E2C failed and no case was created.

  • A possible reason for the error is Case.SuppliedEmail which is limited to 80
  • A more likely reason is your understanding of EmailMessage.ToAddress

A string array of email addresses for recipients who were sent the email message. Include only email addresses that are not associated with Contact, Lead, or User records in Salesforce. If the recipient is a contact, lead, or user, add their ID to the ToIds field instead of adding their email address to the ToAddress field. Then the email message is automatically associated with the contact, lead, or user. You can’t send emails unless there’s at least one recipient

As this is an array, there may be an internal limit of 121 bytes per email address.

It is highly likely that the inbound email is spam. You would need to check your mail server (which will receive this email before it is forwarded to SFDC) to be sure. If you have the timestamp of the error, your IT department should be able to see the inbound email

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.