Fix duplicate customer rows in a manufacturing report
Find true duplicate customer records in a manufacturing CSV, keep valid order rows, remove repeats, and check the cleaned report before sharing.
A manufacturing report may list the same customer several times, even when the data is correct. One customer can have separate work orders, products, delivery sites, or reporting dates, so removing every repeated name can erase real production records.
First decide what makes a row a duplicate, then remove only records that match that rule. The CSV Editor can open a CSV, help you find and edit entries, sort rows, and remove duplicates in your browser.
Check the report for duplicate rows
- Open the CSV Editor and load the manufacturing report. Keep an untouched copy of the original file so you can recover rows if you remove too much.
- Read the column headings and compare a few suspected repeats. Look for fields such as customer ID, customer name, work order, product or part number, production date, site, and report period.
- Decide which columns together identify one unique record. For example, a customer ID alone is usually not enough if a customer can place several orders. A combination of customer ID, work order, and line item may be a better match for an order-level report.
- Use the editor's duplicate-removal action only after choosing a rule. Start with exact duplicate rows if you are unsure. Review the remaining data, then save a cleaned copy rather than replacing the original.
Do not remove a row just because the customer name appears twice. A repeat might represent a separate batch, shipment, production line, or order. When the report will be used for billing, inventory, or compliance, confirm the matching rule with the report owner before deleting records.
Choose what counts as a duplicate
Every column matches
If two rows have the same value in every column, one may be an accidental copy. Removing one exact repeat is usually low risk, but check whether the report intentionally records repeated events as separate entries. Some exports include a timestamp, sequence number, or status field that makes otherwise identical records distinct.
The customer matches, but order details differ
These are not necessarily duplicates. A shared customer ID with different work orders, part numbers, dates, or delivery locations often represents valid activity. Keep both rows unless the report's rules say those fields should not create separate records.
The name matches, but the customer ID differs
Names can be shared by different businesses, typed differently, or changed after a merger. Use a stable customer ID when available. If there is no ID, compare another reliable field, such as account number or billing location, and ask the report owner before combining records.
Some identifying fields are blank
Rows with missing IDs or order numbers are hard to match safely. Do not treat all blank values as one customer or one order. Set these rows aside for review, and correct the source data if you can identify the missing values.
How to fix the duplicate rows
- Keep the original report unchanged. Make a separate working copy before editing. This gives you a way to restore a removed row and compare the final version with the source.
- Check the fields that identify a record. Use the report's customer ID and the relevant transaction fields, such as work order or production date. Match at the level the report represents. A customer summary and an order-detail report need different duplicate rules.
- Look for small formatting differences. A customer ID with an extra space, or a name with different capitalization, can look like two entries. Use find and edit to correct only the field you have verified. Do not change IDs or customer names based on guesswork, because leading zeros and punctuation may be meaningful.
- Sort to make related rows easier to compare. Sort by the chosen identifying fields, such as customer ID and work order. Nearby rows are simpler to inspect, especially when a report has many customers or multiple production dates.
- Remove only confirmed repeats. Use duplicate removal for exact row matches first. If the editor lets you choose which columns determine a duplicate, select only the fields in your approved rule. If you cannot set that rule, review questionable groups manually instead of removing them automatically.
- Check the cleaned report before sharing it. Compare the row count with the original and inspect several customer groups, including ones with multiple orders. Confirm that valid work orders and line items remain, then save the result as a new CSV file.
Check that the cleaned report is still usable
Open the cleaned file again and check that the columns still line up under their headings. Look at records containing commas, quotation marks, or leading zeros, since those values can be damaged by careless editing or by opening a CSV as plain text. Confirm that dates and IDs still appear as expected in the saved file.
Also compare totals that matter to the report, such as the number of orders, units, or production lines. Removing a duplicate customer record should not silently remove a distinct order. If a total changes unexpectedly, return to the original and inspect the rows that were removed before using the cleaned file.
Why customer names alone are a risky match
A customer is an entity, while a report row may represent an order, shipment, item, facility, or production event. Those are different levels of detail. If you deduplicate an order-level report using only the customer name, you can collapse several legitimate orders into one and understate activity.
Use the narrowest reliable key that matches the report's purpose. For a customer summary, the customer ID may be enough. For production details, add the work order, item, line, or date as needed. Keep a note of the rule you used so another person can understand why certain rows were removed.
The CSV Editor works with the file in your browser, so the report stays on your device while you review and edit it.
