Forum Discussion
Error ordering Sizes
I have a table that I want to represent in an orderly way according to the Size, but different sizes can be registered and I get the error "You can not sort by the column "Letter" "by Ntalla". You can not have more than one value in "Ntalla" .... Choose a different column to sort or update the data in "Ntalla". In a matrix I do not get the order I require
Well the Table has the order in which they should come out.
| 34571 | ctd | TallaO | OrdenTalla |
| 34571 | 38 | 3 | 2 |
| 34571 | 63 | 4 | 3 |
| 34571 | 63 | 5 | 4 |
| 34571 | 63 | 6 | 5 |
| 34571 | 89 | 7 | 6 |
| 34571 | 89 | 8 | 7 |
| 34571 | 63 | 10 | 8 |
| 34670 | 147 | XS | 1 |
| 34670 | 227 | S | 2 |
| 34670 | 325 | M | 3 |
| 34670 | 322 | L | 4 |
| 34670 | 220 | XL | 5 |
| 34670 | 63 | 1X | 6 |
| 34670 | 30 | 2X | 7 |
| 34670 | 20 | 3x | 8 |
| 34649B | 100 | S | 1 |
It comes out like this, but it should be 2.3 etc ... or S, M,L ... since the column with which it should be ordered is that of Ntalla, I have not achieved 😞 it
Array without order
- Anonymous4 years ago
Hi Syndicate_Admin ,
According to your statement, I think you want to sort [TallaO] column by [OrdenTalla]. However, I find there are multiple duplicates sort numbers in [OrdenTalla] for different [TallaO].
For example:
TallaO = 10, OrdenTalla = 8
TallaO = 3x, OrdenTalla = 8
This will make Power BI confused which one should be sorted in 8.
So you will get error when you sort [TallaO] column by [OrdenTalla]. I can reproduce your issue in my test.
I find that there are multiple sort number when TallaO equal to S.
TallaO = S, OrdenTalla = 1
TallaO = S, OrdenTalla = 2
This will casue error as well. Due to this situation, we can not add another new sort to achieve your goal.
So I suggest you to add [OrdenTalla] in Matrix column field in top level.
Best Regards,
Rico ZhouIf this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
5 Replies
- amitchandakSuper User
Syndicate_Admin , Create a new column like this and use that as sort column
new OrdenTalla =
if( not [OrdenTalla] in {"S", "XS", "M", "L", "XL", "1X", "2X", "3X", [new OrdenTalla] + 20)Modify as per need
- Syndicate_AdminAdministrator
Graccias me sale el error Column 'new OrdenTalla' cannot be found or may not be used in this expression.
I understand that if the Size number is not in the matrix it should be increased or create a larger number?
- AnonymousNot applicable
Hi Syndicate_Admin ,
According to your statement, I think you want to sort [TallaO] column by [OrdenTalla]. However, I find there are multiple duplicates sort numbers in [OrdenTalla] for different [TallaO].
For example:
TallaO = 10, OrdenTalla = 8
TallaO = 3x, OrdenTalla = 8
This will make Power BI confused which one should be sorted in 8.
So you will get error when you sort [TallaO] column by [OrdenTalla]. I can reproduce your issue in my test.
I find that there are multiple sort number when TallaO equal to S.
TallaO = S, OrdenTalla = 1
TallaO = S, OrdenTalla = 2
This will casue error as well. Due to this situation, we can not add another new sort to achieve your goal.
So I suggest you to add [OrdenTalla] in Matrix column field in top level.
Best Regards,
Rico ZhouIf this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- Syndicate_AdminAdministrator
thank you I understood what the problem was.
- AnonymousNot applicable
Hi Syndicate_Admin ,
Could you tell me if your problem has been solved? If it is, kindly Accept it as the solution. More people will benefit from it. Or you are still confused about it, please provide me with more details about your problem or share me with your pbix file without sensitive data.
Best Regards,Rico Zhou