SharePoint Designer Workflow problem with Lookup column There is a particular scenario in which you might receive the below error if using SharePoint Designer List Workflow.
Coercion Failed: Unable to transform the input lookup data into the requested type. Workflow Scenario Consider a SharePoint list called "Employee" with following schema.
Employee Name (Text)
We create a SharePoint Designer workflow to send a simple email with Employee Name and Country when an item is created.
After publishing the workflow, let us see try creating a few items and see the outcome.Workflow Problem
Though the workflow is pretty simple. We note that it worked fine where lookup values are the United Kingdom, United States, Spain, Australia, but fails when the lookup value is blank. It gets 'Canceled' in this case. If we look closely at the workflow history, it shows these details -
Event Typ - Error User ID - System Account Description - Coercion Failed: Unable to transform the input lookup data into the requested type
The description is useful for us - Coercion Failed: Unable to transform the input lookup data into the requested type.Analysis and Troubleshooting
This happens when you use a Lookup site column in workflow and the value is BLANK/NULL. The workflow fails when transforming the Lookup data (blank in this case) into Lookup Value (as Text). Further steps of the workflow will not be reached and it gets canceled and logs the error.
How to fix - Resolution
The solution to this is converting the Lookup value to a string and then using it in workflow stages.
- Create a Workflow Local Variable named "country" of type "string".
- Modify the workflow by adding an if condition to check if the Lookup value is not-empty (is not empty).
- Set the variable to the Lookup Value
- Add further stages after the if condition. Add an else condition if required.
After modifying the workflow this way, even null/empty/blank lookup values will be converted to a blank string value.
Make sure you do this for every lookup column if you feel the value can be blank anytime.
- error CAML Query containing special characters
- [Solved] SharePoint Illegal operation attempted on a registry key that has been marked for deletion
- Trigger Flow on selected Listitem from SharePoint view - create button with JSON column formatting
- SharePoint Excel error - The workbook cannot be opened because it contains the following features that are not supported by Excel in the browser
- Send Email with attachment using SharePoint PowerShell, SMTP server
- How to show or hide columns in SharePoint Online List Library from
- SharePoint excel error - A problem occurred while connecting to the server. If the problem continues, contact your administrator.
- How to get SharePoint Online user details from person or group column using REST API
- How to get SharePoint List Item URL using PowerShell
- How to get the SharePoint Tenant Login URL
- Special character & not working with SharePoint REST API
- How to disable SharePoint subsite creation option for owners
- Managed Metadata error - The data returned from the tagging UI was not formatted correctly
- Deploy SharePoint wsp solution package using PowerShell
- How to create classic site in SharePoint Online
- See actual SharePoint error exception modify web.config
- 'Edit Document' Requires a Windows Sharepoint Services-compatible application and Microsoft Internet Explorer 6.0 or higher
- How to enable anonymous public access for SharePoint Online site collection, file, folder without login ?
- SharePoint installation error - Setup is unable to proceed due to the following error This product requires Microsoft .Net Framework 4.5
- How to add animated Gif to SharePoint Online Page
- [Solved] SharePoint Search Internal server error exception
- How to create SharePoint Document Library
- SharePoint - Use Today's Date Time in list view filter and calculated column
- How to redirect SharePoint Site Collection to different URL
- SharePoint error cannot connect to the configuration database
- XmlRpcException ConnectException connection refused error - Java
- How to connect to SSH port other than default 22 - Linux
- Android Emulator 5.1.1 not loading on Mac OS X Android Studio - Android-Studio
- Toast not getting displayed Android App - Android
- How to Open Trash on Mac - MacOS
- #HappyBirthdayJimin trending Happy Birthday Jimin BTS Army - BTS
- Enable spell check in Sublime Text (macOS) - MacOS