Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Good Afternoon,
I have randomly received an error message regarding data type mismatches, no data types have been changed in the data source or in BI Desktop and this has never happened before, does anyone know what can randomly cause this error?
I have gone through all the columns and reassigned all the data types and it still shows an error shown below - any help would be much appreciated 🙂 Thank you!
= let
tableWithOnlyPrimitiveTypes = Table.SelectColumns(Source, Table.ColumnsOfType(Source, {type nullable number, type nullable text, type nullable logical, type nullable date, type nullable datetime, type nullable datetimezone, type nullable time, type nullable duration})),
recordTypeFields = Type.RecordFields(Type.TableRow(Value.Type(tableWithOnlyPrimitiveTypes))),
fieldNames = Record.FieldNames(recordTypeFields),
fieldTypes = List.Transform(Record.ToList(recordTypeFields), each [Type]),
pairs = List.Transform(List.Positions(fieldNames), (i) => {fieldNames{i}, (v) => if v = null or Value.Is(v, fieldTypes{i}) then v else error [Message = "The type of the value does not match the type of the column.", Detail = v], fieldTypes{i}})
in
Table.TransformColumns(Source, pairs)
Solved! Go to Solution.
Hi @pigsinblankets ,
This issue appears when your data structure changes and data type conversion failed.(due to data type not matched) Can you confirm these files has same data structure?(e.g. data type, field name, separator... )
You can try In Query Editor, right-click the column and use Replace Values.
If the problem is still not resolved, please provide detailed error information and let me know immediately. Looking forward to your reply.
I have also found similar posts, please refer to.
Solved: expression.error the type of the value does not ma... - Microsoft Power BI Community
Solved: Data rows error - Microsoft Power BI Community
Best Regards
Community Support Team _ Rongtie
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @pigsinblankets ,
This issue appears when your data structure changes and data type conversion failed.(due to data type not matched) Can you confirm these files has same data structure?(e.g. data type, field name, separator... )
You can try In Query Editor, right-click the column and use Replace Values.
If the problem is still not resolved, please provide detailed error information and let me know immediately. Looking forward to your reply.
I have also found similar posts, please refer to.
Solved: expression.error the type of the value does not ma... - Microsoft Power BI Community
Solved: Data rows error - Microsoft Power BI Community
Best Regards
Community Support Team _ Rongtie
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
User | Count |
---|---|
107 | |
89 | |
81 | |
76 | |
73 |
User | Count |
---|---|
112 | |
104 | |
96 | |
74 | |
66 |