← All postsHow-to

Import validation: catching bad data before it lands

Import validation checks data before and after loading. What to test, why load reports mislead, and how to make a rollback possible.

How-toI

Import validation is the set of checks run before and after data is loaded into a system. A load that reports zero errors has confirmed that the format was acceptable, not that the data is right — and the difference is where bad records enter and stay.

What import validation should catch

  • Structural problems: wrong column count, bad delimiters, broken encoding.
  • Type errors: text in numeric fields, invalid dates, out-of-range values.
  • Referential gaps: records pointing at parents that do not exist.
  • Duplicates against existing data, not only within the file.
  • Business rule violations the system itself does not enforce.
  • Silent conversions, where the destination accepted a value by changing it.
  • Field mapping errors, which pass every technical check and still put data in the wrong place.

Why load reports mislead

Because they measure acceptance, not correctness. A date coerced to a different format, a truncated description, a picklist value quietly set to the default — all of these are successful rows in the report. The only reliable checks compare against the source: counts by category, totals of numeric fields, and a sample of records read end to end by someone who knows what they should say. That last check finds in ten minutes what reconciliation reports miss entirely, because a person notices that a customer is in the wrong country while a total does not.

Test with the worst real data, not with clean examples. The file that breaks an import is the one with an apostrophe in a company name, a negative quantity, a date in 1899 and a comma inside a quoted field — and that file exists in every real export.

Making rollback possible

  1. Load into a staging environment first, with the same validation rules as production.
  2. Take a backup immediately before the production load, and verify it restores.
  3. Tag imported records with a batch identifier so they can be found and removed.
  4. Load in batches rather than one transaction, so a failure is partial and diagnosable.
  5. Keep the source file exactly as loaded, since the question later is what was sent.
  6. Agree in advance what constitutes failure and who decides to stop.

Ettex Forms suits the validation rules applied at entry as well as at import, so the same standards govern data however it arrives.

Frequently asked

Does a clean load report mean the data is correct?

No. It means the format was acceptable. Coerced dates, truncated text and defaulted picklists all appear as successful rows.

What is the most effective check?

A person who knows the data reading a sample of records end to end, alongside counts and totals compared against the source.

How is rollback made possible?

Staging first, a verified backup, batch identifiers on imported records, and loading in batches rather than one transaction.

MI
Written by Maria I.

Part of the Ettex team — writing about product, engineering and the future of work.

More posts
Get the best of the Ettex blogProduct news, guides and tips — straight to your inbox, no spam.