Skip Navigation

[Resolved] Split: Price sorting does not work as expected

This thread is resolved. Here is a description of the problem and solution.

Problem: I have a View that is sorted by a custom field. The field holds numbers that represent prices. The sorting seems to be wrong, and prices are appearing out of order.

Solution: Check to make sure the sorting feature is setup to sort using data type "UNSIGNED" or "number", not "string."

Relevant Documentation:
https://toolset.com/documentation/user-guides/filtering-views-by-custom-fields/

This support ticket is created 6 years, 9 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Our next available supporter will start replying to tickets in about 1.64 hours from now. Thank you for your understanding.

Sun Mon Tue Wed Thu Fri Sat
8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 8:00 – 12:00 - -
13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 13:00 – 17:00 - -

Supporter timezone: America/New_York (GMT-04:00)

Author
Posts
#616047

Hi, thanks for your helpfull, but I still need more help.
I don't know what happened but now if I do a search with price value or the other between filter, the search return wrong results...
For example, if I do a search by price from 0 to 20.000, the results have some properties with price same as €120.000 or other value over 20.000.

Why?

#616146
Screen Shot 2018-02-14 at 3.19.08 PM.png

Hi, please see the attached screenshot. The price filter uses the data type "string", but should probably use "number" instead. Try "number" and let me know if the problem is not resolved.

#616181

Hi, thanks for help. I have solved the issue, I don't have seen this function into query settings!!!

But, the results return is too slow, same as I have reported in the primary ticket!!!