• Hi.

    I’ve sorted my participant lists to look at a numeric field (MMR / player rank) and display results descending order. For the most part it works, as most numbers are between 1000 and 2000. However there are a few low ranking players with scores below 1000, and these appear at the top of the list.

    It’s almost as if the plugin is seeing 900 > 1000, like it’s looking at the first number or something?

    The page I need help with: [log in to see the link]

Viewing 1 replies (of 1 total)
  • Plugin Author xnau webdesign

    (@xnau)

    You mention that the feild type is numeric, that is neccesary for the comparisons to be made numercially instead of alphabetically, so you may want to check to make sure the field type is specifically “Numeric” or “Decimal”.

    If the numeric field is not sorting as expected, you should take a look at the configuration of the database table to make sure the field is getting stored as a numeric value. Normally the plugin sets this up, but there may have been some reason that didn’t work in your case.

    You’ll need to inspect the database table using phpMyAdmin or similar. this application is typically found in your hosting control panel. The table is named wp_participants_database. Look at the “Structure” tab and find the name of the numeric field. Make sure the “Type” is a numeric type such as “bigint” or “decimal” for example:

    In this example, the field is named “numeric”

Viewing 1 replies (of 1 total)
  • The topic ‘Bug sorting numeric list by descending’ is closed to new replies.