AL1-3 in HL7 v2: A Field Guide to Allergen Code/Mnemonic/Description
AL1-3 is where the segment stops being abstract and says what the patient is actually allergic to. It is also the field most likely to arrive as inconsistent free text instead of a clean code, which is exactly the kind of mess your test data should be reproducing.
AL1-3 is a coded element (data type CE) that names the specific allergen: a substance, medication, or ingredient. It typically carries a coded value, a matching text description, and the coding system used, though many real-world source systems only populate the free-text portion.
What this field contains
Example
AL1-3 is "PENICILLIN^PENICILLIN^L": a locally coded identifier, its text description, and the coding system flag.
Where this trips people up
Plenty of production interfaces send AL1-3 as text-only, something like "PCN" or "no known drug allergies" jammed into the description component with the identifier and coding system left blank. A test suite built exclusively on fully coded CE values will look complete and still fail the moment a real feed sends a bare string. There is also a subtle trap in the "no known allergies" case: some systems represent it with a specific AL1-3 value rather than omitting AL1 entirely, and if your downstream logic treats any populated AL1-3 as "patient has an allergy," you will generate false positives on every NKDA patient. Test both patterns explicitly.