Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagejavascript
  pjs.define("result", { type: 'packed decimal', length: 10, decimals: 0 });
  pjs.define("Ds1", { type: 'data structure', qualified: true, elements: {
    "num": { type: 'integer', length: 3, decimals: 0, initValue: 123 },
    "extra": { type: 'date' },
    "char": { type: 'char', length: 20 }
  }});

  pjs.define("Ds2", { type: 'data structure', qualified: true, elements: {
    "char": { type: 'char', length: 20 },
    "diff": { type: 'char', length: 5 },
    "num": { type: 'packed decimal', length: 3, decimals: 0 }
  }});

  pjs.assignCorresponding(Ds2, Ds1);
  result = Ds2.num;

 


RPG Equivalent

EVAL-CORR