--- title: "CheckEdifactPreParser" slug: "check-edifact-pre-parser" updated: 2026-08-18T13:55:11Z published: 2026-08-18T13:55:11Z canonical: "docs.lobstersoftware.com/check-edifact-pre-parser" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.lobstersoftware.com/llms.txt > Use this file to discover all available pages before exploring further. # CheckEdifactPreParser | **Class name** | com.ebd.hub.datawizard.parser.CheckEdifactPreParser | | --- | --- | ## Description This Preparser can be used in an error handling Profile (profile 2) for profiles with an EDIFACT source structure (profile 1). If the EDIFACT profile (profile 1) generates an error when reading in an EDIFACT file, the error handling profile (profile 2) is called. The preparser (in profile 2) receives the source structure and the EDIFACT file (from profile 1) and performs an error analysis. The result of the analysis is delivered by the preparser in the form of input data for the error handling profile (profile 2), where it can then react accordingly, depending on the error. **Profile 1**: - Document type "EDIFACT" with EDIFACT source structure. - Enter the error handling profile (profile 2) in [Error handling](/v1/docs/en/profiles--tab-1-6). - Example profile: [Profile-EDIFACT_profile.pak](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/Profile-EDIFACT_profile.pak) - Erroneous sample file (missing character (') at the end of the FTX segment): [example.edi](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/example.edi) ```plaintext UNB+UNOA:3+5400110000009:14+5013546107732:14+010502:1237+2722166169492+++I+0+EANCOM+1' UNG+ORDERS+5400110000009:14+5013546107732:14+010502:1237+1+UN+D:96A:EAN008' UNH+1+ORDERS:D:96A:UN:EAN008' BGM+220+C1441747' DTM+137:200105022200:203' FTX+PUR+1++THIS IS AN EXAMPLE OF EDIFACT FILE. NAD+BY+5400110000009::9' NAD+SU+5013546107732::9+COMPANY ABC' LIN+1++5400111864181:EN' PIA+1+8641800:BP' IMD+C++CU::9:WIDGETS' IMD+F++:::0.7066 EURO' MEA+PD+LAY:4+NAR:6' MEA+PD+ULY:4+NAR:48' QTY+21:288' QTY+59:12' PRI+AAA:12.80:CT:AAE' SCC+7' UNS+S' UNT+21+1' UNE+1+1' UNZ+1+2722166169492' ``` **Profile 2:** - Must have Input agent "Message". - Must have this preparser here set ("Preparsing by" field, see [Extensions](/v1/docs/en/profiles--tab-1-2)). - The preparser gets the source structure and the input data from profile 1 and delivers an error analysis as output, which profile 2 gets as input data. Profile 2 has the EDIFACT file as backup file. **NOTE:** The structure of the error analysis can be obtained by setting the checkbox "Result of preparser overrides backup file" (see [Extensions](/v1/docs/en/profiles--tab-1-2)**)**. In the example profile here, however, a suitable source structure has already been created. - The profile allows error handling of an EDIFACT file not successfully parsed in profile 1 without profile 2 running into an error. - Example profile: [Profile-EDIFACT_error_handling_profile.pak](https://cdn.document360.io/4be90b94-ec83-41d8-963e-962df16110d4/Images/Documentation/Profile-EDIFACT_error_handling_profile.pak) - The following is the raw error analysis for this example. ```plaintext result;error err;1;7;FTX;"Found more fields than defined in segment: FTX+PUR+1++THIS IS AN EXAMPLE OF EDIFACT FILE.NAD+BY+5400110000009::9" ... ``` The first line is a header. The format of the error lines: | ;<[record number](/docs/en/profiles--entry-tab-4)>;;; | | --- | Optional intermediate phase before Phase 2. A preparser manipulates input data before the parser processes it; for example, to remove special characters or convert an unknown format to a supported one. A profile is the central configuration unit in the Lobster Data Platform. It receives data, processes it, and forwards it. Configuration is done graphically, with no programming required. International EDI standard established by the UN for electronic data interchange. EDIFACT defines message types such as ORDERS, INVOICE, and DESADV. Configuration in Phase 2, which determines the format of the input data. The document type determines how the parser reads the data and transfers it to the source tree. Examples: EDIFACT, XML, JSON, CSV, X12. The input agent receives data in Phase 1 and starts a job for further processing. It works either as event based (passively waits for data) or scheduled (actively fetches data).