Reference·HL7 v2·ROL
HL7 v2 Reference

HL7 v2 ROL Segment Guide: Fields, Format, and Testing Gotchas

Jul 28, 2026 · 6 min read

ROL shows up quietly in all kinds of messages — orders, scheduling, even ADT — and it can repeat several times in a row to name the attending provider, the referring provider, and the consulting provider one after another. Test suites that only ever generate one ROL per message never exercise the logic that keeps those repeats straight.

Quick answer

ROL is the Role segment in HL7 v2. It identifies a person or organization participating in a message in a specific capacity, such as attending provider, referring provider, or consulting provider, and it can repeat multiple times within a single message to capture each participant separately. Downstream systems typically use ROL to populate care team rosters, provider attribution on orders, and referral routing.

The fields that actually matter in practice

ROL-1 →
Role Instance ID — a unique identifier for this specific occurrence of the role, used to track or update it later without touching the others
ROL-3 →
Role-ROL — the coded value describing what kind of role this is — attending, referring, consulting provider, and similar — usually pulled from a locally maintained table
ROL-4 →
Role Person — the identifier and name components of whoever is filling the role, structured much like other person-name fields elsewhere in the message
ROL-5 →
Role Begin Date/Time — the timestamp marking when this role became effective, which matters most when a role changes hands mid-encounter

Example

Synthetic example Generated by Synthibase
ROL|1|UP|AT^Attending Provider^SYNTHIBLOCAL|5521987^HALVORSEN^MARIA^^^DR^MD|20260728080000
ROL|2|UP|RT^Referring Provider^SYNTHIBLOCAL|4498210^OKONKWO^DAVID^^^DR^MD|20260727093000

Two synthetic ROL segments from the same message, one for an attending provider and one for a referring provider. All names and identifiers are fabricated.

Where this trips people up

Because ROL can repeat, teams building integrations often write parsing logic that assumes exactly one instance and grabs whichever ROL segment appears first, silently discarding the rest. That works fine in a hand-built test file with a single attending provider, then breaks the moment a real message arrives with an attending, a referring, and a consulting provider stacked back to back. The other common gap is Role Instance ID reuse: if a generator resets ROL-1 to the same value across unrelated role additions, any downstream logic that updates or removes a specific role by that ID ends up touching the wrong one.

Epic vs. Cerner vs. MEDITECH: An Interoperability Comparison
HL7 ADT Messages: A01 through A08 Explained
Generate multi-role test messages without the manual assembly
Synthibase can produce messages with several correctly sequenced, synthetic ROL segments — attending, referring, consulting, and more — so your provider-attribution and care-team logic gets real coverage before go-live.
Start free trial →
This page is written independently by Synthibase for testing and informational purposes. It is not an official publication of HL7 International or X12/Washington Publishing Company, and is not a substitute for reviewing the official standard or your trading partner's companion guide. See our Terms of Service for full legal terms.