Sales Sale FK Fix

Repairs sales_sale.company_id and sales_sale.country_id. For every already-migrated sales_sale row — from the very first to the most recent — this re-reads the current source row, translates each FK below through the current parent mappings, and corrects any column that disagrees.

Update-only: a parent that was never migrated, or a source id of 0/-1, is left alone — nothing is created or auto-copied. A value that is any valid mapping for its parent is treated as correct. The same rule is applied to the newest rows by Mapping FK Sweep.

  • sales_sale → sales_company salesCompanyId → sales_sale.company_id
  • sales_sale → country salesCountryId → sales_sale.country_id

Preview runs the exact same reads and resolves the exact same expected values, but skips the write. Every run — preview or real — produces a downloadable Excel report of the changes found.