Issue with compatibility of older compiled artefacts in .NET / JVM COBOL

over 1 year ago


In Visual COBOL 4.0 and Visual COBOL 5.0, in an extremely small and limited set of cases, there is an issue running older .NET executables and dll, and older JVM .class files. Specifically, for the problem to occur, ALL of the following must be true.

  1. Your application must do an IS NUMERIC condition test on a variable declared with USAGE NATIONAL.
  2. The code being run must have been created with Visual COBOL 3.0 or earlier.
  3. The code must be run using Visual COBOL 4.0 or 5.0.

The problem is that the IS NUMERIC test may give the wrong answer.


The resolution is to recompile any program that uses this construct.

In order to resolve this issue fully, in Visual COBOL 6.0 the .NET and JVM COBOL runtimes will reject any program using IS NUMERIC on a NATIONAL item that was compiled with an earlier (i.e. 5.0 or earlier) product, issuing a “missing method” exception. The resolution is to recompile.

For the avoidance of doubt, if a program does not use NATIONAL data, it is completely unaffected by this issue. Furthermore, if a program is compiled and run using the same version of VC there is no problem.

Comment List
Related Discussions