Analyze and Relink Line Files
Description
  • Sage 100 ERP applications use 'Line Files' to store detail information for a specific record.
  • These files are usually distribution detail files for data entry records (for example: invoices and journal entries).
  • A Line File is a linked list, or chain, of detail records associated with a header record.
    • For example, you distributed a single invoice to several General Ledger accounts during Accounts Payable Invoice Data Entry.
    • The linked list structure allows an unlimited number of detail records to be associated with a header record.
    • It also facilitates deletions and insertions of detail records.
  • In the event of a hardware or software malfunction, a file's linkage information becomes damaged. Damaged Line Files result in:
    • Missing detail records
    • Listing or printing records out of sequence
    • Error messages that display when printing or maintaining a 'Line File'
Cause
Resolution

Notes

  • The utility repairs links and indexes for Line Files.
  • It doesn’t repair damaged data.
  • Use Rebuild Application Sort Files to repair sort files, and Rebuild Key Files to repair key files.
  • The utility doesn't affect User-defined fields (UDFs).
  • UDFs link to records through Line Index, which never changes.
  • You need Supervisor rights to run this utility.
     CAUTION: Use caution when working with this task. Always make a backup first. 
  • Contact Sage Customer Support if you need help.

To Relink line files

  1. Select Library Master, Utilities, Analyze and Relink Line Files.
  2. Click OK, at Warning.
  3. Select the Module, then select Company Code from the lookup.
  4. The window lists all line files for the selected application.
  5. The cursor starts at the first Line Detail File. Click another file to select it.
  6. Double-click the highlighted file, or click Select to change Relink from No to Yes.
  7. The cursor moves to the next file automatically.
  8. Click All to select all files. Leave Relink as No if you don’t want to rebuild.
  9. When finished, click Proceed.
  10. At Do you want to save original files, click Yes to save a duplicate before rebuilding.
  11. Backup copies use the original name plus.old in the *\MAS90* directory under application/company data.
    • For Example, old and APAABC.old appear under \MAS90\APABC if you select Yes.
  12. Click No. This will relink without saving a copy.
     CAUTION:   This program can cause data loss if you have corrupted files. Always select Yes to keep a backup. 
  13. At Do you want to print the Error Log, click Yes to print Remove Chain details.
  14. The system generates Remove Chain details even if all data file links are correct.
  15. Click No to skip printing the Error Log. You can’t print this report later.
  16. After printing, the original dialog appears with Application. Click Cancel, X to close the utility.

Error log messages and information

LINK ERROR IN HEADER
Header Key

  • This message means a header record links to an index outside the line detail range.
  • The system resets the pointer to zero, leaving the header record without line detail.
  • A detail item couldn’t relink with its header record and the system likely removed.
  • Examine the order or check number for missing detail items.
  • If the utility relinks SO2 and sees Link Error in the header, check the referenced sales order numbers.
  • Check the Error Log to confirm the order still has all line detail.

DETAIL RECORD LINE POINTER OUT OF RANGE 
 Line Key 
 Line No.
This message indicates that a particular line detail record is linked to an index number outside the range of the line detail file. The system resets the pointer to zero.

DETAIL RECORD WITH INVALID HEADER
This message indicates that a detail record exists but the header record doesn’t exist (orphaned record). It’s removed.

DETAIL RECORD RELINKED
RELINKED FOR HEADER 
 Line Key  
 Index No.

  • The system relinked a line detail record due to a header/line key mismatch or pointer issue.
  • The system provides the line record key and index number for review.
  • Verify that headers don’t contain duplicate detail records.
  • The system found an orphaned detail record and relinked it to the header record.
  • If you added the missing detail later, duplicates can exist.
    • For example, the same line item could appear twice on a sales order.
[BCB:155:Chat 100 US:ECB]

 

Steps to duplicate
Related Solutions

How to Rebuild Key Files in Sage 100
What is data corruption?