Data table sorts numbers incorrectly

Hi Andrew,

The sorting of number columns in HUI data tables seems to be incorrect. I have a column containing the integers 1 through 19, which when I sort smallest to largest appear as below:

1
10
11
12
13
14
15
16
17
18
19
2
3
3
4
5
6
7
8
9

So it appears it is sorting them as strings i.e. on a digit-by-digit basis.

1 Like

yes, at present that component only accepts string data. image

1 Like

I see, thanks for the reply. I will have to manually sort the data before displaying it for the time being.

If you need help testing any updates to it in the future let me know :pleading_face: :wink:

Thanks again for your work!

Maybe pad your text with a zero? (ie. β€œ01”, not β€œ1”)

2 Likes

Good idea, although I don’t think that will solve the issue if a list contains both positive and negative numbers. Thank you though