Function Problems

How to Move Completed or Shipped Rows to the Top in Excel

Aamir Naveed AkramAamir Naveed Akram Nov 11, 2026 870 views

Question details

The user needs to organize an inventory worksheet by moving rows with completed shipment information to the top.

How to Move Completed or Shipped Rows to the Top in Excel
Product
Excel
Device & OS
not provided
Scenario
Organizing and tracking an inventory or order worksheet based on shipment status.
Observed behavior
The user wants to group all completed or shipped orders at the top of the dataset for better visibility and management.
Before you start

Ensure your inventory dataset is formatted as an Excel Table (Ctrl+T) so that formulas in helper columns automatically apply to newly added order rows.

Solution 1Recommended

Use a Helper Column with XLOOKUP and Custom Sort

Extract the shipment date or status into a single auxiliary column using XLOOKUP, then sort the table by this new column.

This method consolidates shipment completion data from multiple columns into a single auxiliary column, making it simple to sort the entire table without losing row integrity.

1
Create a Helper Column

Insert a new column at the end of your inventory dataset (e.g., Column F) and name it 'Shipment Date' or 'Status'.

2
Apply the XLOOKUP Formula

Select the first empty cell in the helper column and enter an XLOOKUP formula to extract the shipment date from your data columns (e.g., columns C:E). Press Enter to apply.

3
Sort the Table

Click the drop-down filter arrow on your new helper column's header. Choose 'Sort Newest to Oldest' or 'Sort A to Z' depending on your data type to bring the completed rows to the top.

Use a Helper Column with XLOOKUP and Custom Sort
Maintaining Data Integrity: Always verify that your data is formatted as an Excel Table or select the entire data range before sorting. Sorting only one column will misalign your inventory records.
Organize Data Effortlessly

Sort and Filter Inventory Worksheets with WPS Spreadsheet

WPS Spreadsheet offers powerful sorting, filtering, and lookup functions like XLOOKUP, making it incredibly simple to organize large inventory and order tracking sheets.

  1. 1. Open your Spreadsheet: Launch WPS Office and open your inventory Excel file.
  2. 2. Add a Helper Column: Create a new column and use the built-in XLOOKUP function to pull the shipment dates into one unified column.
  3. 3. Apply Custom Sort: Navigate to the Data tab, click Sort, and select your helper column to arrange all shipped items neatly at the top of your sheet.
Fully compatible with Microsoft Excel formulas, including XLOOKUP and VLOOKUP.Advanced Sort and Filter tools to quickly organize shipment data.Lightweight software with a familiar, user-friendly interface.Completely free built-in templates for inventory and order management.
microsoft office alternative - wps office

Frequently Asked Questions

Can I automatically move shipped rows to another sheet instead of sorting them?

Yes. You can use the FILTER function on a new worksheet to automatically pull in rows from your main inventory sheet where the shipment status is marked as 'Completed' or 'Shipped'.

Why did my rows misalign after applying the sort?

This usually happens if you only select the helper column before sorting. To prevent this, format your data as a Table (Ctrl+T) or ensure all columns in the dataset are selected before clicking the Sort button.

Does the XLOOKUP function work in older versions of Excel?

XLOOKUP is only available in Microsoft 365 and Excel 2021 or newer. If you are using an older version, you can achieve the same result using a combination of INDEX and MATCH functions.