There are COBOL debugging functions as follows:
TRACE
CHECK
COUNT
Memory Check
COBOL Error Report
Compiler Listings
These functions can be very useful in trapping problems that are difficult to reproduce in production situations.