Saturday, April 24, 2021

Einstein Analytics: "Fix" data with Update transformation

Scenario: there are changes in the business, based on the revision given, we need to update data stored in an existing dataset or create a new dataset.

Solution: use dataflow, in this scenario, we are going to use the update node, which is not so commonly used in the dataflow.

JSON behind update node

 "updateMaster": {
    "action": "update",
    "parameters": {
      "left": "getMaster",
      "update_columns": {
        "ID": "ID",
        "Desc": "Note"
      "right": "getRevision",
      "left_key": [
      "right_key": [

For the register node:

  • Put the same Alias/Name to the master dataset if you want to overwrite it, the existing dashboard will work as per normal
  • Use different Alias/Name from the source master dataset if you want to create a new dataset, you need to edit the existing dashboard to use the new dataset created. 


Monday, April 19, 2021

Empowering People and Businesses Through Technology

This blog appeared first on

At Salesforce, Nichola Palmer works with customers to bring their stories of innovation and transformation to life. In this blog series featuring Trailblazers, Nichola introduces Johan Yu, a Salesforce MVP, business systems architect, blogger, and author, based in Singapore. Johan loves using the power of data for the benefit of all business stakeholders.

In the remote Indonesian village where Johan Yu grew up, electricity was a rare luxury. Therefore, all tasks connected to his father’s farming business were done manually. Along with the farming itself, these included record-keeping of expenses, crop production levels, and sales accounts.

At school, Johan began to learn about computers. Very soon, he recognised the power such technology would bring to his father’s business, as well as his community. Johan wasn’t thinking of anything sophisticated like artificial intelligence (AI), machine learning, or robotic automation. Such technology was still a long way off. He could simply see that certain jobs were better left to machines, enabling humans to be better at what they do.

“At my high school, we had a computer lab and I became very interested in computers,” says Johan. “Once my teachers knew I was interested in computer science, they guided me on a path to study at university in Jakarta.”

Johan earned a Bachelor of Computer, Management Information Systems, at Jakarta’s BINUS University. Then, he took a Master of Management, Information Systems, at BINUS University and Australia’s Curtin University. 

While studying,  Johan realised his dream could come true. As a child, he had imagined using the power of computing to help businesspeople like his father. Today, he is a business systems architect and Salesforce MVP, who works with businesses to solve problems using technology.

Becoming “skilled, more competent, and faster”

For seven years during and following university, Johan worked for an insurance firm. Then he moved to Sydney, Australia, and took a job with the country’s first Salesforce partner. Immediately, the Salesforce platform made sense to him. It wasn’t so much about what it did, but more about what it allowed him to do.

“I had come from using basic systems to building applications,” Johan says. “And I realised there were a lot of things that I thought IT professionals shouldn’t have to do any more.

“I saw that we could focus more on how technology can enable the strategic needs of the business, rather than just the infrastructure required. The capabilities of the technology enabled us to think about the business in a different way.”

The capabilities of the Salesforce platform made him feel “skilled, more competent, and faster”, Johan says. In the past, he had never experienced a strong community around a platform or brand. So when he had challenges, it was sometimes difficult to find solutions. But once he discovered how active the Salesforce community was, he realised he was able to find answers immediately, from Trailblazers all over the world.

“I appreciated the speed to execute,” he says. “In the past, I had to spend a long time setting up the server, the database, and more. But the Salesforce platform is so convenient. I could just start working on projects immediately. And reach out to the community for help when needed.”

Success = user experience + empowerment

Johan is currently working in a multinational company, from his home in Singapore, with more than 10,000 people around the globe. How does he ensure they’re all making the most of a platform or application that has been developed for them? 

“We try to make sure apps are simple for users to understand and interact with,” he says. “We don’t want to put too much effort into documentation. If it is user-friendly, then it makes sense. If it’s not user-friendly, it’s just wasting money.”

Importantly, Johan says, technology is not about replacing people. Its true power, as he realised when he was a young boy, is in making people even better at what they do.

“In the corporate world, we don’t use AI to replace people. We use it to enable people,” he says. 

“Our people can use AI to see how likely it is that a sale will close. The propensity to close is based on historical data and on the experience of similar customers. So, the AI helps salespeople to prioritise their work. We see that it makes them more successful.”

Leading the Salesforce community in Singapore

In Singapore, Johan is well-known as a generous leader within the Salesforce community. He is considered a knowledgeable expert, who spends a great deal of time helping others to find solutions to powerful business challenges.

This assistance includes a Salesforce-themed blog site, managed and written by Johan, which attracts more than  2,200 people every day from around the world. Most of his visitors are not from Singapore. They come from the USA, UK, and India. His reputation has spread around the globe.

The prolific sharer of knowledge has also written three books. They are Salesforce Reporting and Dashboards, Salesforce Lightning Reporting and Dashboards, and Getting Started with Salesforce Einstein Analytics.

“One of my passions is sharing knowledge with other people,” Johan says. “It’s something I really enjoy. The community has always given me answers fast and shared its knowledge, so I like to do the same.”

Sunday, April 11, 2021

Salesforce: Query User Assigned with Package License

Scenario: your company purchased X licenses for a package software installed in Salesforce, what is the easy way to extract users has been granted with that package software?

Solution: open the Package Details then click the "Manage Licenses" button. However, this is not easy when you have thousands of users.

Alternative solution: use SOQL, so we can extract the data easily.

1. Query the Package Id

You need to know the Namespace Prefix of the package to get the Package Id. You can get the Namespace Prefix from Package Details, including allowed licenses and used licenses.

SELECT Id, NamespacePrefix, AllowedLicenses, UsedLicenses, CreatedDate, ExpirationDate, Status FROM PackageLicense ORDER BY NamespacePrefix

2. Query User Package License object

SELECT Id, PackageLicenseId, CreatedById, CreatedDate, UserId FROM UserPackageLicense

By query UserPackageLicense object and filter with PackageLicenseId, you can get :
- UserId: user assigned with the license
- CreatedById: who grants the license
- CreatedByDate: when is the license granted

But unfortunately, you can't use relationship query for UserId to get the name and profile and so on, so you need to query to User object again, subscribe for this KI.

Monday, April 5, 2021

Search in Lightning Experience

Here a few items to note related to search in Lightning Experience:

  1. Not all standard objects and standard fields are searchable in Salesforce, check out this article, and this article to make additional fields searchable.
  2. For custom objects, Allow Search option must be enabled.
  3. You can filter your search result to a specific object.
  4. Limit the number of results by entering more specific search terms. For example, enter the full name and company (Mike Jones Salesforce). 
  5. As you type, you will see suggested records:
    • Recently accessed items
    • Results that match Name field values
  6. After a record is created or updated, it can take a few minutes for the new text to be indexed and become searchable. A record doesn’t show in the search results until it’s in the index. Wait a few minutes and search again.
  7. The search engine only returns results you have permission to view.
  8. Ensure the object has a tab created. Objects without a tab aren't returned in search results, Tab visibility for the affected User's assigned profile is set to 'Default On' or 'Default Off' and not Tab Hidden.
  9. If your search contains punctuation, phone, email, or special characters and you’re not getting the right results, try your search with white spaces in place of the punctuation, check out this article.
  10. Formula fields are not searchable.
  11. The field that contains the keyword does not need must be in the page layout.


Sunday, March 28, 2021

Salesforce: Lightning Email Template

There are 2 permissions related to the Lightning Email Template:

  1. Create Folders for Lightning Email Templates
  2. Manage Public Lightning Email Templates
Both of the permission names above are obvious on what permissions are given by enabling each of them.

Folders and Enhanced Sharing

If Folders and Enhanced Sharing for Lightning Email Templates have not been enabled, navigate to the Setup menu and search for Lightning Email Templates.

Once enabled, the email template folder and sharing access will similar to the report and dashboard folder, users with the above permissions will be able to:

  • Create folder and sub-folder to store Lightning email template
  • Share folder by user name, roles, public groups, territory
  • Share folder with access: manage, edit, view

Create Folder and Email Template

Navigate to the Email Templates tab, if you do not see it, click the 9-dots icon and type Email Templates. From here, you can create a New Email Template and New Folder. To create Sub Folder, open a folder and click the "New Folder" button, access to users in the subfolder will follow access given to the main folder.

Once the folder created, you can give the folder access to your team members, then start creating email templates. You should insert merge fields to increase your user's productivity by typing fewer words when sending email, sample:

Make sure to select the correct Related Entity Type, store it in the right folder, and make use of the merge field function.

You also can add files into the email template, when the user selects the email template, those files will be automatically added as attachments.

Additionally, users can store the email template in the Private Email Templates folder, so no other users can access or change it.

Using Email Template

In this sample, the email template created is for Case, make sure Email is added in Lighting Action on the Case page layout.

Open a case, click the Email tab, then select the email template created in the previous step.

Click the 3rd icon to insert an email template, including adding files as email attachments (1st icon), adding merge field (2nd icon), preview email (4th icon), clear and revert email template selected (5th icon), and pop out the email editor (6th icon).

Monday, March 15, 2021

Salesforce: Adding Signature in Email

It is pretty simple to add an email signature in Salesforce, so all email sent out will have your signature at the bottom of the email. Click your avatar, select Settings then My Email Setting.

Adding Image and clickable links

However, many users would like to add the company logo or special image in their email signature, how to add this? 

You can't simply copy and paste the image to the signature box. So, a little effort here, you need to upload the image to "somewhere" so it is available for the public, such as

Or, you can upload the image to Files in Salesforce, here is the step

1. Go to the Files tab and upload the image
2. Open the image and click Public Link
3. Click the "Create Link" button, then click the Create button
4. Copy the link, e.g.
5. Open the link in a new browser tab
6. Right-click and select "Open image in new tab", copy the URL from the new tab, e.g.

Now we can put the URL into our email signature, but before that let us learn a bit of basic HTML

<img src="img_girl.jpg" alt="Girl in a jacket" width="500" height="600">

The above is an HTML sample to show an image on the web browser, including our email signature. We can replace "img_girl.jpg" with our long URL from step (6), replace alt value, and remove width and height for the original image size.

So, here the email signature result

Let us reduce the size of the image and add some clickable links by tweaking the HTML
<b>Johan Yu</b>
Visit <a href="">SimplySfdc</a>
Click here to <a href="">email me</a>
<img src="" alt="my logo" width="275" height="56">

Page-level ad