Skip to main content
spencer_engel
Expert ⭐️
December 19, 2019

How to create a URL in the Rules Engine

  • December 19, 2019
  • 20 replies
  • 2095 views

Today’s tutorial covers how to create URLs in the Rules Engine. A good use case for this, as I describe in the video, is if you need to tokenize links to multiple Salesforce records in the CTA comments or scorecard comments. In my example, I tokenize links to two Opportunity Products and then include those in the CTA comments. 

 

 

The guide for how to put these URLs together can be found via this link: 
https://www.w3schools.com/tags/att_a_href.asp. The instructions are to use the concatenate formula field in a transformation task, then put in the following code: 

 

<a href=”  

hit enter

Input your URL - in my case it was https://na85.salesforce.com/

hit enter

Then tokenize whatever it is you want to link to; in my case the opportunity product ID

hit enter

“>

hit enter

Type in the text you want the link to display; in my case “Link to Product”

hit enter

</a>

hit enter and save

 

Let me know if you have any questions! 

20 replies

sarahmiracle
VIP ⭐️⭐️⭐️⭐️⭐️
June 17, 2022

@Syed what do you mean it shows whole in the export? Can you share an example of what your export looks like?

Customer Success Systems Admin @ Amplitude, 3x Gainsight CS Ops Product Council Member
Contributor ⭐️⭐️⭐️
June 20, 2022

@sarahmiracle , i mean in output, wen i test the rule. It shows like below:

 

Helper ⭐️
June 20, 2022

@Syed That’s correct, the export will show the URL but in the tool and report builder you will see the formatted text in a clickable link. If you add the field to a report and export it will show the full url. I confirmed in my instance the same behavior.

Contributor ⭐️⭐️⭐️
July 5, 2022

@jkolle thanks for your help.Its working fne but in order to URL to work, i do right click and open in new tab.Is there anyway, if we can do with one click?thanks

Contributor ⭐️⭐️⭐️
July 5, 2022

hi 

Currently, i am using like this

Concat(<a href=",https://lightning.force.com/,Record ID, target="_blank", ”>,Link,<,/a>

 

sarahmiracle
VIP ⭐️⭐️⭐️⭐️⭐️
September 19, 2022

Hi all - I wanted to share that I ran into an issue with this solution after the new Data Operations was introduced. The new Data Operations now has a validation step for String values that will not allow you to save updates made in Data Operations when you have String field values that exceed a certain character limit. I have 11 fields that I use this ^ solution for and use Rules Engine to populate the field value, which works successfully. This now means that using this solution means I cannot use Data Operations at all, as all of these fields will hit that same error.

I’m submitting a ticket to Support, but I wanted to raise here as well because I believe you will all be in the same boat.

Customer Success Systems Admin @ Amplitude, 3x Gainsight CS Ops Product Council Member
Contributor ⭐️
January 10, 2023

@sarahmiracle - I had the same issue as you, where it creates what looks like a clickable link, but you can’t click it. I even tried what you did and typed out the URL in case a space was causing an issue, but it was still not working. 
I am using Gainsight NXT. I am creating the hyperlink via a rule and writing it to a string field. 
 

Concat Formula in Rule
Report view of output looks like you can click it but nothing happens

Any suggestions would be helpful! 

Contributor ⭐️⭐️⭐️⭐️
June 23, 2023

Hi Team,

I am creating milestone activities via rule and trying to insert a URL into notes section and this solution doesn’t work.. Any suggestions?

 

 

Expert ⭐️
June 23, 2023

Got this to work with two adjustments.

 

  1. I add the <p> tags
  2. I have the target="_blank" piece added in

 

 

 

I dont think the target blank is needed as that’s to open in a new tab.

 

Something I noticed on yours also

 

 

Contributor ⭐️
November 7, 2023

Very useful post