What Is HL7 v2 PV1-1? Set ID, Explained for Testers
Most messages only ever carry a single PV1 segment, so PV1-1 sits there as a harmless "1" for years — until a message type that legitimately repeats PV1 shows up and an interface that assumed a constant value starts silently overwriting visit data.
PV1-1 is the first field of the PV1 segment — a simple incrementing sequence number used to distinguish multiple PV1 segments when more than one appears in the same message.
What this field contains
Example
The first field (1) marks this as the sole PV1 segment in the message. Synthetic patient — not a real person.
Where this trips people up
Parsers that hardcode an assumption of "exactly one PV1 per message" tend to ignore PV1-1 entirely, which works fine until a message type or trading partner sends a legitimate repeat. When that happens, code that keys visit records off segment position instead of PV1-1 will overwrite the first visit with the second instead of storing both — a bug that only surfaces once real-world message variety hits the interface.