REFX Contract Index Adjustment Data Extraction

The program below lists all the indexations that have occurred for a REFX lease contracts. ( For contracts that have not had or will never have any indexations, some info is available in table VIAJSEPCINDX (fields INDEXSERIES and INDEXBASEYEAR) )

For a given contract ID it derives the INTRENO (internal object ID).

The INTRENO is used to get all relevant records in VIAJRECORD. The records that correspond to past indexations have a status 3 in field ADJMDRECORDSTAT (‘Adjustment Complete’).
Other useful info => ADJMFROMOLD and ADJMFROMCALC (previous index date and index adjustement date)

Each record in VIAJRECORD is linked to a record in VIAJRECINDX via PROCESSGUID + INTRENO.

In VIAJRECINDX you can retrieve INDEXSERIES/INDEXBASEYEAR + ADJMINDEXBASE (index value at adjustement date) and FIRSTINDEXBASE (reference index at initial date of index calculations).