How to Link a CAPA to ERP Lots and Serial Numbers for Containment and Effectiveness
how to link CAPA to ERP lot numbers and serial traceability
Also searched as
- CAPA affected lots ERP genealogy report
- containment scope from ERP lot traceability
- CAPA effectiveness check using ERP data
- which shipped orders contain this lot
Short answer
A CAPA is only as good as its containment scope, and the scope comes from ERP genealogy: forward trace from the suspect raw material lot or process to every job, serial and shipment that consumed it, and backward trace from the failed serial to its components. Store the CAPA number against those ERP records, then use ERP rejection and return data to verify effectiveness.
Applies to: Any manufacturing ERP with lot and serial control (SyteLine, SAP, NetSuite, Epicor, Infor LN and M3, Oracle EBS) and any QMS; AS9100 clause 10.2, ISO 9001 clause 10.2, FDA 21 CFR 820 style corrective action expectations
Scoping and tracking a CAPA with ERP data
- 1Capture the trigger as ERP identifiers: part, lot, serial range, job or work order, PO receipt, work center and date range, not a narrative description.
- 2Run a backward trace from the failure: serial or lot to the job, then to component lots and the receipts they came from.
- 3Run a forward trace from the suspect lot, tool, operation or date range: to every job and serial that consumed or passed through it, then to shipments and customers.
- 4Split the result into stock still on site (quarantine via NCR), WIP (hold the jobs), and shipped (customer notification decision).
- 5Store the CAPA number against the affected lots and jobs in the ERP, or store the ERP list in the CAPA record, so the link works in both directions.
- 6Define effectiveness criteria in ERP measurable terms before closing: reject rate for the operation, returns for the part, repeat NCR count for the cause code.
- 7After the agreed period, rerun the same query and attach the result to the CAPA as the effectiveness evidence.
Traceability depth decides containment quality
Forward and backward tracing both depend on what the ERP captured at the time. If receiving did not record the supplier lot, if issues to the job were posted against a part number with no lot, or if lot-controlled items were consumed by backflush with default lots, the trace stops at the part number and your containment scope becomes the whole stock history. That is the real argument for lot control on critical items and for capturing the supplier lot and heat or batch number at receipt.
Check what your ERP actually holds before the first CAPA needs it. Pick a shipped serial and try to produce its job, operations, component lots and supplier receipts in under an hour. If you cannot, that gap is a finding to fix, and it is more valuable than any single CAPA.
What the trace query looks like
ERPs store genealogy in transaction history tables: material issues to jobs, lot-to-lot relationships, serial history, and shipment lines. The names differ by system, so use your ERP's documented genealogy report or API where one exists, and a query over the issue and shipment transaction tables where it does not. The shape of the query is the same everywhere: start from the suspect lot, find issue transactions, resolve to jobs, resolve jobs to produced lots and serials, resolve those to shipment lines.
-- Generic forward trace shape (table and column names vary by ERP) SELECT j.job_no, p.lot_or_serial, s.ship_doc, s.customer, s.ship_date FROM material_issue mi JOIN job j ON j.job_no = mi.job_no JOIN job_output p ON p.job_no = j.job_no LEFT JOIN shipment_line s ON s.lot_or_serial = p.lot_or_serial WHERE mi.component_lot = :suspect_lot ORDER BY s.ship_date;
Containment decisions on the result
Each row of the trace needs a decision. On-site stock goes to quarantine through the NCR process. Jobs in progress are put on hold at the next operation. Shipped quantity needs a risk assessment: does the nonconformance affect form, fit, function, safety or a contractual requirement, and do you have an obligation to notify the customer or authority? Aerospace and defense contracts often require notification of escapes, so record who decided and when.
Keep the decision per lot, not per CAPA. A single CAPA commonly covers three lots with three different outcomes: one scrapped, one reworked and re-inspected, one shipped and accepted by the customer under a concession. The record must be able to show that.
Effectiveness checks that mean something
Closing a CAPA because the corrective action was implemented is not the same as it being effective. Effectiveness means the problem did not recur, and the ERP can show that: first-pass yield for the operation, scrap by reason code for the part, vendor returns by cause, customer returns and warranty claims by part and serial range.
Write the check as a saved query at CAPA creation and put a calendar date on it. A common window is one to three production cycles or a fixed number of lots, depending on volume, and low-volume parts may need a lot-count criterion rather than a time one.
Common pitfalls
- !Defining the CAPA scope as a part number because lots were never captured, forcing a recall of everything.
- !Backflushing lot-controlled components with default or dummy lots, which destroys genealogy.
- !Stopping the trace at the first shipment and never checking whether the shipped part was used as a component by the customer or a downstream job.
- !Using implementation of the action as the effectiveness evidence.
- !Recording containment as one blanket decision instead of per lot and per shipment.
How an ERP-grounded AI assistant handles this
Genealogy tracing is a good fit for a grounded assistant because the question is precise and the answer is a query result. Asked which jobs and shipments consumed a given lot, an ERP-grounded assistant can build and show the trace query, return the job and shipment list, and draft the effectiveness query for the CAPA file. It reads under the user's ERP role, and containment actions, such as holding jobs, remain human decisions.
Frequently asked questions
Can I do a CAPA without lot-level traceability?
You can, but the containment scope will be broader and less defensible, because you cannot prove which units were unaffected. For critical items, especially safety or flight related ones, lot or serial control is effectively required. For low-risk commodity parts, a date range scope may be acceptable if you document the rationale.
Where should the CAPA record live?
Usually in the QMS, since it carries the root cause, actions, approvals and effectiveness review. The ERP should hold references to the CAPA number on affected lots and jobs, and the CAPA should hold the ERP identifiers it covers, so a search from either side finds the other.
How long should an effectiveness check run?
Long enough for the failure to recur if the fix did not work. For high volume parts that may be a few weeks or a few hundred units. For low-volume or long-cycle products it is better to specify a number of lots or builds. Your quality procedure should state the rule, and the reviewer should be someone other than the action owner.
Related
How to Sync an NCR From Your QMS to ERP Quarantine and MRB Disposition
The reliable pattern is two events: when the NCR opens, the ERP moves or flags the affected lot or serial into a non-nettable quarantine status; when the Material Review Board closes it, the disposition (use as is, rework, repair, scrap, return to vendor) triggers exactly one matching ERP transaction. The NCR number is the key that ties both sides together.
How-toHow to Issue a Supplier Corrective Action Request (SCAR) Using ERP Receiving and Reject Data
Supplier quality starts with three ERP datasets: PO receipts (what arrived and when), receiving inspection results (what failed and why), and NCRs or vendor returns (what it cost). Join them by supplier and part to compute reject rate and on-time delivery, set thresholds that trigger a SCAR, and attach the evidence lots to the request so the supplier can investigate.
How-toGauge Found Out of Tolerance: How to Find Affected Product Using ERP and Calibration Data
When a calibration finds a gauge out of tolerance, you must assess every product it measured since its last in-tolerance calibration. That is only possible if inspection records carry the gauge ID. Record the gauge on each inspection result, then query by gauge and date window to list lots, jobs and shipments, and raise NCRs for any that are doubtful.
How-toHow to Send Production and Labor Reporting from MES to ERP
Treat the ERP work order as the system of record for cost and quantity, and the MES as the system of record for what physically happened. Send one confirmation message per operation (or per shift or lot) containing work order, operation sequence, good quantity, scrap quantity with reason, and labor start/stop per employee and work center, post it through the ERP's supported transaction API, and make the message idempotent so a retry never double-posts.
How-toHow to Calculate OEE from MES Data and ERP Standards
OEE equals Availability times Performance times Quality. Availability comes from MES run and stop events against planned production time, Performance compares actual output to the ideal cycle time (usually the routing standard from the ERP), and Quality is good units divided by total units. The numbers are only trustworthy if planned time, ideal cycle time and the good/scrap split are defined once and used consistently.
AdvancedISA-95 and B2MML: How to Integrate ERP with MES
ISA-95 defines the boundary between business systems (Level 4, the ERP) and manufacturing operations (Level 3, the MES) and the information that crosses it. B2MML is the XML implementation of those models. In practice you exchange a ProductionSchedule from ERP to MES, and ProductionPerformance, plus material and equipment information, back, mapping each element to your ERP's work order and confirmation APIs.
AI for ERPAI for NCR, CAPA, and 8D Drafting in AS9100 and ISO 9001 Quality Systems
AI drafts NCR, CAPA, and 8D reports from ERP quality data for engineer review, cutting drafting time under AS9100 and ISO 9001 without changing sign-off.
AI for ERPAI for AS9100 Quality Management on Your ERP
AI on top of your ERP quality module for AS9100D suppliers: NCR/CAPA drafting, FAI support, counterfeit parts screening, with a full audit trail.
Stuck on QMS to ERP integration?
Talk to engineers who work inside QMS to ERP integration every week, and who build private AI that answers these questions from your own ERP data.