Description
Code 12s are extremely rare. They're generated when there is a discrepancy in your invoice based on a variety of calculations.
How to Prevent Valid Code 10s
Review your EDI 810 (invoice) to be sure that it exactly matches the Purchase Order (EDI 850).
Can it be Disputed?
Technically code 12s are available to be disputed in APDP, though we've not seen much success here. In most cases your best bet is to initiate a dispute with your buyer.
How to Dispute Invalid Code 12s
Supporting documentation:
Invoice (EDI 810) showing the correct information
Purchase Order (EDI 850) that matches the invoice