Jump to content

Recommended Posts

Posted

Hello,

I'm trying to use the String Utilities Search and when I paste the Result in the Timeline, all I'm getting back is '257'.

If I paste in the Outcome it says 'success' and if I paste in Match Found, it says 'true' in the Timeline.

Please could someone tell me where I'm going wrong?

Many thanks,
Alisha

stringUtilsSearch.png

Timeline Update.png

Posted

That would be correct, the result is the index of the match:

image.png

I can't really explain where you're going wrong because you haven't said what you're trying to do.

 

Posted

Hi Alisha,

At the top of most Hornbill Automations there is a ? that you can click on to get more information

 

image.png

 

The help for this Automation says that the Result returns the index of the match.  I'm assuming at the moment that the index is the number of characters at which point this was found in the email text. 

image.png

Having a number returned is correct in this case.  Could you let us know what you were expected or what the outcome is that you are trying to achieve?

Many thanks

 

Posted

Thank you @Steve Giller and @James Ainsworth.

 

I was trying to find the name of the analyst within the source email so I could then store the name in a custom field and then assign the request to the analyst. I was hoping the search would be an easy way to extract the analyst's name from the email, but I don't fully understand how all the String Utilities work. Your help with this would be much appreciated. 🙂

  • 3 weeks later...
Posted

Hi @Steve Giller,

I now have the Analyst's details output to the Timeline using the Regex Substring. However, when I try to update the Owner with that result, it doesn't work.

Is this the correct variable that should be used?
&[global["flowcoderefs"]["stringUtilsRegexSubstr"]["result"]]

Many thanks,
Alisha

Assign to owner.png

Posted

I'm slowly getting there... If I remove the first and last name and just keep the User ID, it has updated the Owner! (Our Handle contains the first name, last name and User ID.)

Posted
On 3/3/2023 at 8:03 AM, Alisha said:

I was trying to find the name of the analyst within the source email

image.png

25 minutes ago, Alisha said:

Is this the correct variable that should be used?

Yes, but you will then need to use that to get the User ID

Note:
 You updated as I was typing this, but I didn't want to waste the effort by not posting!

  • Like 1
Posted
On 3/3/2023 at 9:02 AM, Steve Giller said:

As for the Regex Expressions to use - everyone hates Regex so you may be on your own there.

Anyone got the new Bing?

I haven't tested this exact one but that's where I now get Regex from !

(?<=\s)[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}

image.thumb.png.2a347b57e2868d85222b20bf09e6d65e.png

Posted

I personally wouldn't trust Bing to tell me I was using Bing, to be honest.

Also that REGEX would match on:
 .user@email.co.uk.com.inf.org 
which I'm pretty sure is not valid - so maybe Bing as a starting point, but double-check it thoroughly.

  • Like 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...