Reason 1 – Numerical Data Converted into Text Format
The issue can occur if the data we are trying to sort is in Text format. We can only sort data from largest to smallest if the data is numerical.
Solution: Use VALUE Function to Convert Text to Numeric Data
Steps:
- Add a new column named Converted Data.
- Select cell D5 and enter the following formula.
=VALUE(C5)
- Press Enter to convert the data into the General format.
- AutoFill the formula to the rest of the column to change the Text format into the General format for all data.
- Select all the data and press Alt + A + S + S to open the Sort dialogue box.
- In the box, check the box of My Data has headers.
- Select Converted Data in Sort by.
- Choose Largest to Smallest in Order and press OK.
- The sorting issue will be fixed.
Read More: [Solved!] Excel Sort Not Working
Reason 2 – Extra Space Before or After Numerical Entry
The second reason for getting the sort from largest to smallest not working in Excel can occur because of the presence of extra spaces before or after a numerical value. To check if any extra space is present in the data:
Steps:
- Insert a column named Check.
- Select cell D5 and add following formula.
=ISNUMBER(C5)
- The formula will show FALSE if extra space is present and it will show TRUE otherwise.
- AutoFill this formula to the rest of the cells to check all the data.
Solution: Apply TRIM Function to Remove Spaces
Steps:
- Add a new column named Converted Data and enter the following formula in cell E5.
=TRIM(C5)
- Hit Enter , and it will remove any extra space that is present in the cell.
- AutoFill this formula to the rest of column E and remove all the extra spaces.
- Select column E and press Alt + A + S + S .
- The Sort dialogue box will pop up.
- In the box, check the My data has headers option.
- Select Converted Data and Largest to Smallest.
- Press OK.
- The data will be correctly sorted.
Read More: [Fixed!] Sort and Filter Not Working in Excel
Reason 3 – Numbers Generated Using Formula
Another reason this problem can occur is if you try to sort numbers that are generated using any formula. In the following example, the numbers are generated using the RANDBETWEEN function. If we try to sort these numbers, the numbers get randomized and the sort doesn’t work properly.
Solution: Copy and Paste As Values
Steps:
- Select all the data generated using a formula and right-click on it.
- Select Copy.
- Click on cell C5 and right-click.
- Select Paste as Values.
- Press Alt + A + S + S to open the Sort pop-up box.
- In the box, make sure the box of My data has headers option is checked.
- Choose Quantity Sold in Sort by and Largest to Smallest in Order.
- Hit the Enter button.
- The sorting issue will be fixed.
Reason 4 – Mixture of Different Data Types
Sort largest to smallest not working in Excel can also occur if the data we are trying to sort are of different types. If some data are in General and others are in Text format, the Sort feature won’t work correctly.
Solution: Convert Data into Number Format
Steps:
- Select all the data from column C.
- Click on the Home tab and go to Home → Number → Number
- Once all the data are in Number format, open the Sort dialogue box.
- In the box, check the box of My Data has headers.
- Select Converted Data in Sort by.
- Choose Largest to Smallest in order.
- Press OK.
- The sorting issue will be fixed.
Note: When the data you want to sort is generated by any formula, it is best to copy and paste those data as values before sorting.
Read More: Excel Not Sorting Numbers Correctly
Download Practice Workbook
Related Articles
<< Go Back to Excel Sort Not Working | Sort in Excel | Learn Excel
Get FREE Advanced Excel Exercises with Solutions!