Forum Discussion
Eliane
Dec 30, 2024Copper Contributor
Sort cells in a table with Xlookup
Hello everyone :) I have a little problem.. For my work I have to create a table “Project planning”, which is fed with information from another table “Customer export”. Using the “Xlookup” function...
Kidd_Ip
Jan 01, 2025MVP
Try below:
- Convert to Values: The "Xlookup" function likely returns dynamic values, which might be causing the sorting issue. Try converting the lookup results to static values:
- Select the relevant columns in the “Project planning” table.
- Copy them (Ctrl+C).
- Right-click and choose "Paste Special" > "Values".
- Recreate Table: Ensure the “Project planning” table is defined as an actual table (Insert > Table), which supports sorting and filtering functionality:
- Select the range with your data.
- Go to the "Insert" tab and click on "Table".
- Check for Hidden Characters: Sometimes, hidden characters or spaces can mess with sorting. Ensure there are no leading/trailing spaces:
- Use the TRIM function in another column to remove any excess spaces.
- Copy the cleaned data and paste it back as values.
- Data Consistency: Verify that all the data types in the “Customer export” table and the “Project planning” table are consistent. Mixed data types can confuse sorting mechanisms.
- Simplify Sorting: Ensure the sorting is straightforward:
- Select the entire table by clicking any cell within the table.
- Go to the "Data" tab and click "Sort".
- Choose the column to sort by (e.g., Customer Name).