  COBOL and External Variables? 
 The Question is:
 
We are moving from an Alpha DEC DS20 to an Alpha ES45 System. Have a COBOL
 program which has an EXTERNAL field which is loaded with data in one program
 and referenced in another.
 
If I reference the table initially with a subscript, it results in ACCVIO.
 However, if the first reference is subscripted with a literal value it works.
 
For example:
 
MOVE 1 TO INDX1.
MOVE A1-TABLE (INDX1:100) TO JUNK.
 
  This aborts with ACCVIO.
 
MOVE A1-TABLE (1:100) TO JUNK.
MOVE 1 TO INDX1.
MOVE A1-TABLE (INDX1:100) TO JUNK.
 
  This works fine.
 
To make matters more confusing, an executable copied from the old machine will
 work fine.  The problem occurs only after I relink the executable.  The same
 object libraries are used in both links.
 
COBOL is v2.5.
 
 The Answer is :
 
  First, please upgrade to a supported version of COBOL, such as V2.8.
 
  As for the reported error resulting in an access violation (ACCVIO),
  there are several known problems with V2.5 which have been resolved
  within V2.8, some involving the use of EXTERNAL.
 
  After you have upgraded to V2.8, recompile/relink the program with:
 
    $ cobol/check/noopt
 
 
 Answer written or last revised on  4-JAN-2004 
