Forum Discussion
Numeric and Alphanumeric data loaded into model as TEXT data type but are different in measure
Hello, BI seems to treat data loaded as Text data type differently based on whether the data being loaded as Text is numeric vs alphanumeric.
I have a measure that has 2 filters based on a Text data type:
When the prod id is numeric, the measure works correctly but the measure does not work if an alphanumeric prod id is loaded to model (prod id is always being loaded to model as Text data type)
This is the complete logic for the measure:
If both prod ids are being loaded as a Text data type why does the measure work for the numeric prod id and not for the alphanumeric?
Hello parry2k,
Filter has been added so that the slope calculation is only using rows with the same product id. I'm fairly new to BI and there is probably a better approach.....
5 Replies
- parry2kSuper User
JeanMariePBI what you are trying to achieve by applying that FILTER condition?
✨ Follow us on LinkedIn and to our YouTube channel
I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make effort to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡ Visit us at https://perytus.com, your one-stop shop for Power BI-related projects/training/consultancy.
- JeanMariePBIHelper I
Hello parry2k,
Filter has been added so that the slope calculation is only using rows with the same product id. I'm fairly new to BI and there is probably a better approach.....
- parry2kSuper User
JeanMariePBI if you have product id in a visual, you don't know to put that filter condition in your dax expression, remove that and in a table visual, put product id column and your measure and it should work.
✨ Follow us on LinkedIn and to our YouTube channel
I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make effort to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡ Visit us at https://perytus.com, your one-stop shop for Power BI-related projects/training/consultancy.
- JeanMariePBIHelper I
Thank you, parry2k. I've removed the filters and the measures work properly. Now I understand that the filters were not needed in the dax because the table would automatically filter what I needed. Thanks again!
- parry2kSuper User
JeanMariePBI Glad to hear it worked. I would recommend accepting an actual reply as a solution so that others can easily find it. Just a recommendation.
✨ Follow us on LinkedIn and to our YouTube channel
I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make effort to give Kudos to whoever helped to solve your problem. It is a token of appreciation!
⚡ Visit us at https://perytus.com, your one-stop shop for Power BI-related projects/training/consultancy.