Working with null values in SharePoint can be one of the more frustrating parts of building reliable Power Automate flows. In this Pragmatic Works training recap, Jonathon Silva walks through a practical example that helps users understand how to detect blank values in a SharePoint list and use that logic to control how a flow behaves.
Using an employee timecard scenario, Jonathon demonstrates how Power Automate can check whether a user forgot to clock out the previous day before allowing a new clock-in entry. He also shows how to handle an additional edge case where the SharePoint list is completely empty. The result is a smarter, more reliable flow that responds correctly in both situations.
Jonathon uses a simple SharePoint list called an employee timecard card list. The list contains only a few columns:
The purpose of the list is to track when an employee starts and ends work. A basic flow already exists to create a new clock-in record using a manual trigger. That setup works well for adding new entries, but it creates a problem when an employee forgets to clock out from the previous shift.
If a user clicks the clock-in button again without first closing out the previous entry, the system could create another incomplete record. Jonathon explains that this is where null checking becomes important.
Null values appear when a field in SharePoint has no data. In this example, a blank clock out time means the employee never finished the previous timecard card record. Jonathon shows that instead of blindly creating a new item, the flow should first verify whether the latest record is complete.
If the clock out value is null, the flow should stop the new clock-in action and notify the user. If the clock out value contains data, the flow can safely create a new item.
To solve this, Jonathon adds a Get Items action in Power Automate. This action retrieves records from the SharePoint list and allows the flow to inspect the most recent entry for the current user.
He configures the action with several important settings:
This setup ensures the flow is checking the right employee and the correct record before moving forward.
Once the latest item is returned, Jonathon adds a condition that checks the Clock Out Time field. Because the Get Items action returns an array, Power Automate automatically wraps the logic in an Apply to Each loop.
The condition checks whether the clock out value is equal to null.
Jonathon tests both outcomes to confirm the logic works correctly. First, the flow detects a blank clock out field and sends an email. Then, after adding a clock out time to the SharePoint record, he runs the flow again and confirms that a new item is created as expected.
Jonathon then highlights an important issue many beginners overlook. What happens if the SharePoint list is empty?
In that case, the Get Items action returns nothing. Since there are no records to loop through, the condition that checks the clock out value never runs. That means the flow does nothing, which is not the desired behavior.
To fix this, he adds a second condition before the null check. This new condition uses the length expression to test whether the SharePoint list contains any returned items.
The logic works like this:
This extra step makes the flow much more dependable because it now works whether the list already contains records or is starting from scratch.
Jonathon Silva provides a practical and easy-to-follow lesson on managing null values in SharePoint with Power Automate. Rather than focusing only on theory, he walks through a real-world business example that demonstrates why null handling is essential for flow reliability. By combining a filtered Get Items action, a null condition, and a length check, users can build smarter automations that prevent bad data and improve process accuracy.
For anyone learning how to connect SharePoint and Power Automate more effectively, this is a strong example of how a few carefully placed checks can make a flow far more robust.
Don't forget to check out the Pragmatic Works' on-demand learning platform for more insightful content and training sessions on Power Automate and other Microsoft applications. Be sure to subscribe to the Pragmatic Works YouTube channel to stay up-to-date on the latest tips and tricks.