An Order Import from Excel can fail with Invalid State Length even when the State values look correct, because a reused worksheet tab still holds stale or hidden data.

Problem

Importing orders from an Excel file returns:

Invalid State Length

Clearing cells and deleting rows in the original tab does not help, but copying the same rows into a fresh tab and pasting values only imports fine.

Cause

Excel can keep data in cells you cannot see (values left beyond the visible range, or stray formatting after edits). The importer then reads an over-length or bad State value from the reused tab, even though the cell looks empty or correct. A fresh tab has no leftover data, which is why a values-only paste imports cleanly.

Fix

  1. Select the good rows on the original tab (for example row 1 through the last real data row).
  2. Copy them, then use Paste Special > Values into a brand-new worksheet tab or a new workbook.
  3. Delete the old tab so the import cannot read it.
  4. Save the file and run the Order Import again against the fresh tab.
  5. If it still fails, check the State column for trailing spaces or stray characters, and confirm each value is a valid two-letter state code.

What you should see

The import finishes with no "Invalid State Length" error, and the number of orders imported matches the visible row count.

Related

Zip Codes Cut Off When Importing Files. How To: Import Files.