SAP Message 26166 - There must be a document info record before each classification record

Diagnosis
You want to copy document info records from an external system to yourSAP System.
The sequential file you created in your external system does not meetthe specifications (see "Documentation of transferprogram").

Procedure
Correct the program in the source system that produces the sequentialfile.
Each classification record (record type 5) must be preceded by adocument header record (record type 1).