Headshot of Kenya Shakir next to text that says, "Automate This! — Manage Finances with Flow."

Automate This! — Manage Finances with Flow

By

Welcome to another “Automate This!” In this live-streamed video series, we cover all things automation, from use cases and best practices to showcasing solutions built by #AwesomeAdmin Trailblazers like you. With automation, you can remove manual tasks, drive efficiency, and eliminate friction and redundancy. In this episode, see how Kenya Shakir uses Salesforce to help her eliminate debt.


Use case

Prior to starting my Salesforce journey, I was a certified financial coach, helping people manage their money and debts in a more efficient way for financial freedom. According to Experian, consumer debt is up 10% since 2020. There are three popular ways to pay off debt: the snowball method, the debt avalanche, and debt consolidation. Most people choose either the snowball method or the debt avalanche. The snowball method involves starting at the smallest debt balance and working your way up to the highest balance. The debt avalanche starts at the debt with the highest interest rate, as compound interest can hinder personal finance goals.

When I was a coach, I didn’t know about the power of Salesforce. When I became a Salesforce Admin, I wondered how I could use Salesforce as a potential tool for personal finance management. Instead of having to do the mental work of combing through all your debt accounts to identify which to focus on first, what if a flow could automatically tell you which account has the highest balance or interest rate—and you could decide from there how to conquer it? In comes Flow!

The solution

Here’s how I built a flow to identify my highest balance debt.

Record-triggered flow to identify the highest balance debt.
First, I created a Debt object to track all my debt as individual records. There are four fields from the Debt record that are used in this flow: Balance, Interest Rate, Highest Balance checkbox, and Highest Interest Rate checkbox.

An example of a custom Debt record in a custom app.

We want our Debt records to be as up-to-date as possible, so we have a record-triggered flow that’s triggered whenever a Debt record is created or updated. The flow starts with a Get Records element to find all the Debt records. No debt is left behind!

Get Records element in flow to get all custom Debt object records and ascending sort by name; all the records are stored in a record collection variable called Higher Balance Records, and there are fields for ID, Highest Balance checkbox, Balance, and Name.

Once we get all the records, we need to store them somewhere. I use a record collection variable which I named “Highest Balance Records” since we will use these records to determine which is the highest balance. We will also need to store the record ID, debt Name, Highest Balance checkbox field, and the Balance of the debt.

Before we determine which debt has the highest balance at this current moment, we need to uncheck the Debt record that is currently marked as the highest balance. The first loop of this flow will do that for us. In testing this flow, I realized that there were two Debt records that were Highest Balance = True. For the longest time, I couldn’t figure out why that was, but after sleeping on it, I figured it out!

Collection Filter, Loop, and Assignment elements to un-designate the previous record with the highest balance.

We will use a Collection Filter element to filter out the Debt records housed in the record collection variable “Highest Balance Records” to only store records where Highest Balance = True. This was the very first flow I created from scratch for my own business case so I had never used a Collection Filter before. But, I found it in the element manager and it was exactly what I needed.

Collection Filter element to filter out records where Highest Balance = True.

We need to “reset” those records that are currently marked as Highest Balance = True, as they might not be the highest balance anymore. We use a Loop element to comb through each record and an Assignment element to change that record’s Highest Balance = False.

Assignment element where Highest Balance = False.

We then use another Assignment element to put the current record in our loop into a collection variable for the next step: the Update Records element.

Assignment element to identify current record in loop to be undesignated as highest balance Debt record.

The Update Records element looks into that collection variable we just made to see which record we will update based on the Assignment element. Once we do this for each record, we’ve essentially reset the records. No record has the Highest Balance checkbox checked.

First Update Records element to un-designate the previous highest balance Debt record.

Now that we’ve reset the records, we can sort through all the Debt records and determine which has the highest balance using a Collection Sort element. This element will sort the Debt records by the value in their Balance field and then limit the collection to only one record—the record with the highest balance. We want to put that record through our second loop.

Collection Sort element to sort all Debt records by Balance from Descending order.

Second loop to assign highest balance Debt record.

We use two more Assignment elements, similar to what we did in the first loop, to assign the Highest Balance field (that singular record from the Collection Sort) currently in the loop to True. To do this, we add another Assignment element with a variable that identifies the ID of the highest balance record and use that variable in our last step, an Update Records element.

Assignment element to assign Highest Balance = True for current record in second loop in flow.

Last Assignment element storing record ID of the current highest balance Debt record.

Last Update Records element for the Debt record with the current highest balance.

And, we’re finished! When I go to the list view of all of my Debt records in my custom app, I can clearly see which debt has the highest balance. That way, I can begin allocating as much money as I can and pay the debt off quickly using the snowball method.

Remember, this flow depends on you keeping up-to-date data in your Debt records, so be sure to determine a cadence to update your balances and interest rates. It could be weekly, biweekly, or monthly.

Inspired by my use case? Now it’s your turn!

  • Use Salesforce to track your hobbies or interests. My very first Salesforce project was to track items in my capsule closet. For that one, I didn’t have a flow but I guarantee you I could think of a reason I might need one.
  • Read the Flow Elements Help article to see what’s possible with Flow!
  • Don’t be afraid of flows! Flows are just a collection of tools that make manual processes automatic and cleaner. Starting by making a flow that’s relevant to you is a good idea because you learn about flow building, the elements, and resources in a concrete and tangible way. Think through the process you want to happen and see how Flow can help you achieve your dreams.

Resources

 

Want to see more good stuff? Subscribe to our channel!

SUBSCRIBE TODAY
Leverage flows to process inbound emails with documents

Leverage Flows To Process Inbound Emails With Documents | Automate This!

Welcome to another “Automate This!” In this live-streamed video series, we cover all things automation, from use cases and best practices to showcasing solutions built by Awesome Admin Trailblazers like you. With automation, you can remove manual tasks, drive efficiency, and eliminate friction and redundancy. In this episode, let’s see how Ohad Idan vanquishes shared […]

READ MORE
Improve sales funnel velocity with Flow

Improve Sales Funnel Velocity Using Flow | Automate This!

Welcome to another “Automate This!” In this live-streamed video series, we cover all things automation, from use cases and best practices to showcasing solutions built by Awesome Admin Trailblazers like you. With automation, you can remove manual tasks, drive efficiency, and eliminate friction and redundancy. In this episode, learn how Becka Dente leverages a simple […]

READ MORE
Send a dynamic email to user-defined contacts with flow

Send a Dynamic Email to User-Defined Contacts Using Flow | Automate This!

Welcome to another “Automate This!” In this live-streamed video series, we cover all things automation, from use cases and best practices to showcasing solutions built by Awesome Admin Trailblazers like you. With automation, you can remove manual tasks, drive efficiency, and eliminate friction and redundancy. In this episode, learn how Michael Barnes uses Flow to […]

READ MORE