Is there a way to specify a blank character as the argument for the 'contains' operator in a filter or trigger?

Elliott_Lowe1
Level 9 - Champion Alumni

Is there a way to specify a blank character as the argument for the 'contains' operator in a filter or trigger?

I am trying to find email addresses with a blank character in them, which is invalid in an email address, but may be a typo.  When I use the 'Email Address contains...' filter and type a blank space as the argument, no leads are found because Marketo automatically strips out the blank space in the argument.  I can search for these in SFDC and in Excel by simply typing in a blank space.  Is there a way to do this in Marketo?
Tags (1)
7 REPLIES 7
Anonymous
Not applicable

Re: Is there a way to specify a blank character as the argument for the 'contains' operator in a filter or trigger?

I don't think there is, but I was trying to find one. Neither Marketo, nor Salesforce would let me edit an email to include a space.

Is there an invalid reason for emails with a blank character? I was looking within our instance to see if I could find one, but isn't.
Dory_Viscoglio
Level 10

Re: Is there a way to specify a blank character as the argument for the 'contains' operator in a filter or trigger?

Not a complete solution, but if Marketo supported wildcards you might be able to do it in a contains "* *" fashion... I just voted up an idea here:

https://community.marketo.com/MarketoIdeaDetail?id=08750000000JbxuAAC
Elliott_Lowe1
Level 9 - Champion Alumni

Re: Is there a way to specify a blank character as the argument for the 'contains' operator in a filter or trigger?

Thanks Dory, I voted for this recent Idea, but it has only 12 votes.  You may want to vote for the similar Idea submitted in January 2012 Wild Card for Filters that has 72 votes (although I could swear it had more votes in the past).  Interestingly its status is 'We Like It, But It's Complicated'.
Elliott_Lowe1
Level 9 - Champion Alumni

Re: Is there a way to specify a blank character as the argument for the 'contains' operator in a filter or trigger?

Joe, blank characters are not allowed in an email address unless within quotes and escpaed with a backslash (\).  I'm trying to cleanup old data that didn't have proper validation rules applies when it was entered and that is why I was asking if there was a way to find them, so we could either correct or remove these from our database. 
Anonymous
Not applicable

Re: Is there a way to specify a blank character as the argument for the 'contains' operator in a filter or trigger?

We do have Leads that came through Marketo forms and contain spaces, because someone forgot to change the field type from the default 'text' to 'email' on the form.

SanfordWhiteman
Level 10 - Community Moderator

Re: Is there a way to specify a blank character as the argument for the 'contains' operator in a filter or trigger?

If you want to flag those existing leads as probable typos (can't be absolutely sure, since in extremely rare cases people are using legit emails with spaces) a FlowBoost one-liner will pick them up:

  var emailHasSpaces = /\s/.test({{Lead.Email Address}});

Anonymous
Not applicable

Re: Is there a way to specify a blank character as the argument for the 'contains' operator in a filter or trigger?

Interesting...I didn't know it was possible to enter a space with quotes and a backslash. I am going to try that today. I was trying to create a record that I could search for. My filters in SFDC didn't seem to pull records. Do I have to use the quotes and backslash there?

Two things that would be nice additions: to be able to search for any character within Marketo (looks like we are stuck using excel for cases like this) and have the email invalid field catch then throw an error for common email issues. Heck, it would be cool if you could adjust what gets flagged as invalid.