Decode and Fix: “This Data Type is Unsupported for Evaluation” in Power Apps
One common frustration when building Canvas Apps over Dataverse is encountering this cryptic error:
“This data type is unsupported for evaluation”
This message typically appears when Power Apps cannot process or render a specific Dataverse column type within a control or formula. While it may seem vague, it’s usually tied to specific patterns involving complex column types or runtime data structure mismatches.
In this blog, we'll explore common causes, scenarios, and practical fixes from both a developer and architectural standpoint.
Root Causes of the Error
1. Polymorphic Lookups
Dataverse supports polymorphic relationships (e.g., `Owner`, `Customer`, `Regarding`) that can point to multiple entity types.
These lookups can't be directly evaluated in Power Apps unless you cast the reference explicitly.
Use:
If(
IsType(ThisItem.Customer, Account),
AsType(ThisItem.Customer, Account).Name,
AsType(ThisItem.Customer, Contact).FullName
)
2. Unsupported or Complex Column Types
Dataverse includes some column types that aren’t natively supported in Canvas App formulas—especially custom types, file/image columns, or certain relationship references.
These may return null or trigger evaluation errors unless handled with special logic or transformations.
3. Choice and Multi-Select Choice Fields
Single-select Choices (Option Sets) are easier to evaluate using `Text(ThisItem.ChoiceField)`. However, multi-select choices are returned as a table, not a scalar value.
Use:
Concat(ThisItem.ChoiceField, Value, ", ")
Always check if the formula context supports scalar or table-based operations.
4. Explicit Column Selection (Performance Optimization)
When the "Explicit column selection" setting is enabled in your app, only selected fields are loaded from the Dataverse table.
If you reference a field that hasn’t been selected, it may return blank or throw this error.
Go to:
Data source → Edit fields → Add the missing columns manually
Troubleshooting Steps
Best Practices for Architects & Developers
- Design with Data Types in Mind: Avoid overuse of polymorphic lookups and complex custom columns unless they’re absolutely needed.
- Standardize UI Logic: Create reusable helper functions to evaluate and display polymorphic/choice fields.
- Align Schema & App: Always re-publish and sync changes between Dataverse and Power Apps.
- Monitor Formula Performance: Complex formulas with unsupported data types not only break evaluation but degrade app performance.
Common Pitfall Examples
Label.Text = ThisItem.Customer.Name // ❌ Throws evaluation error (polymorphic)
Label.Text = Text(ThisItem.MultiSelectChoice) // ❌ Invalid for multi-select
Fixed version
Label.Text = Concat(ThisItem.MultiSelectChoice, Value, ", ")
Conclusion
The “This data type is unsupported for evaluation” error is a clear sign that your app and data model are out of sync. Whether you're dealing with polymorphic relationships, multi-select fields, or explicit column selection issues, the key is to:
- Understand the data type behavior
- Use the right functions (`IsType`, `AsType`, `Concat`, etc.)
- Configure your app’s data source correctly
- Test early with real data
With a good grasp of Dataverse internals and Power Apps formula patterns, this error becomes not a blocker—but a signal for more precise modeling and UI logic.
Comments
Post a Comment