Why COBOL's COMP-3 packed decimal format still breaks Pix and ISO 20022 integrations
Brazilian banks, acquirers and fintechs often run instant Pix payments and ISO 20022 messaging alongside core ledgers still built on COBOL mainframes. The article identifies the binary translation layer, especially the COMP-3 packed decimal format, as a frequent but overlooked source of integration failures. In COMP-3, each byte holds two decimal digits and the final nibble encodes the sign, so values like +12345.67 occupy four bytes. Converting through floating-point arithmetic can corrupt cents during end-of-day reconciliation, so the author recommends fixed-precision types such as BigDecimal or integer cent values. The piece also warns that misreading implied decimal points or sign nibbles can produce misplaced or inverted entries that only surface during accounting reconciliation.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.


Discussion (0)
Log in to join the discussion and vote.
Log in