Forum Discussion
Expression.Error: We cannot convert the value 99003114 to type Text.
Hi,
I got Expression.Error: We cannot convert the value 99003114 to type Text after merging queries.
In the source data before merge, value is already changed to text type.
Hi szczuaek,
Thank you for reaching out to the Microsoft fabric community forum and sharing the details and screenshot. Also, thanks to danextian, FarhanJeelani, Shahid12523, for those inputs on this thread. The error you are seeingExpression.Error: We cannot convert the value 99003114 to type TextUsually happens when the column used in your merge is not consistently in the Text format across both queries, or the data type conversion step is applied after the merge step in Power Query. Even if the column looks like Text in one query, if the other query still treats it as a Number (or if the merge happens before the type conversion step), this error can occur.
In both queries that you are merging, make sure the column you are joining on is explicitly set to Text. In the query editor, select the column → Transform > Data Type > Text.
Check the Applied Steps pane in Power Query and confirm the type conversion step appears before the Merge Queries step. If not, move or re-apply it above the merge step.
If you have values that look like numbers (e.g., 99003114) but should be treated as text (like an ID), you can use Text.From([Column]) to enforce that consistently.
https://learn.microsoft.com/en-us/powerquery-m/text-fromAlso, please refer these links:
1. https://learn.microsoft.com/en-in/power-query/data-types
2. https://learn.microsoft.com/en-in/power-query/merge-queries-overviewOnce both sides of the merge are aligned as Text before the join, this error should be resolved.
Hope this helps. Please let us know if you still run into issues after making these changes.
Thank you for using the Microsoft Fabric Community Forum.
7 Replies
- v-kpoloju-msft
Community Support
Hi szczuaek,
Thank you for reaching out to the Microsoft fabric community forum and sharing the details and screenshot. Also, thanks to danextian, FarhanJeelani, Shahid12523, for those inputs on this thread. The error you are seeingExpression.Error: We cannot convert the value 99003114 to type TextUsually happens when the column used in your merge is not consistently in the Text format across both queries, or the data type conversion step is applied after the merge step in Power Query. Even if the column looks like Text in one query, if the other query still treats it as a Number (or if the merge happens before the type conversion step), this error can occur.
In both queries that you are merging, make sure the column you are joining on is explicitly set to Text. In the query editor, select the column → Transform > Data Type > Text.
Check the Applied Steps pane in Power Query and confirm the type conversion step appears before the Merge Queries step. If not, move or re-apply it above the merge step.
If you have values that look like numbers (e.g., 99003114) but should be treated as text (like an ID), you can use Text.From([Column]) to enforce that consistently.
https://learn.microsoft.com/en-us/powerquery-m/text-fromAlso, please refer these links:
1. https://learn.microsoft.com/en-in/power-query/data-types
2. https://learn.microsoft.com/en-in/power-query/merge-queries-overviewOnce both sides of the merge are aligned as Text before the join, this error should be resolved.
Hope this helps. Please let us know if you still run into issues after making these changes.
Thank you for using the Microsoft Fabric Community Forum.- szczuaekRegular Visitor
Thank you, it works now.
- Shahid12523
Community Champion
The error means your merge columns are not both Text.
Fix in short:
- In both queries, set the merge column → Transform → Data Type → Text.
- Make sure this step is before the merge in Applied Steps.
- If needed, create a column:
Text.From([YourColumn])
and merge on that.- szczuaekRegular Visitor
Hi,
All steps are done, and error still appears
- FarhanJeelani
Super User
Hi szczuaek ,
That error is almost always caused by a mismatch in the data types of the join/merge keys between the two queries. Even if one side looks like text in the UI, something in the merge operation can coerce or infer a different type (e.g., number vs text) and Power Query will fail when it tries to join.
To fix it
Make sure the join columns used for the merge have exactly the same data type on both sides.
It's usually safest to coerce both sides to text (or both to number) before merging.
Also clean up any leading/trailing spaces and handle nulls gracefully.
Step-by-step fix in Power Query EditorOpen Power Query Editor.
For both tables involved in the merge:
Identify the join column (e.g., CityId, or whichever you use to merge).
Set the data type to the same type, preferably Text:
Select the column -> Transform (or Home) -> Data Type -> Text.Please mark this post as solution if it helps you. Appreciate Kudos.
- szczuaekRegular Visitor
Hi,
All steps are done, and error still appears
- danextian
Super User
Power Query is trying to change the entire column into type text but at least one of the values in that column isn’t a simple number. It’s actually of type [Type] (a metadata object) - some rows are numbers and texts but others are stored as type metadata instead of scalar values. Instead of directly changing, try creating a new column first that parses the content as text and if the evaluation returns an error a null.
try Text.From([column]) otherwise nullFilter that new column to null and inspect what data type those rows have. What to do after depends on the data type.