HL7 RSP_Q11 Location Segment Pattern Response

HL7 message structure RSP_Q11 groups and segments from HL7 v2.5.1 Hide structure

These are the generated groups and segments for the version selected at the top of the page. The article explains the workflow, and this panel follows the chosen HL7 version.

Message Structure

SegmentNameRequiredRepeatable
Message Header Yes No
Software Segment No Yes
Message Acknowledgment Yes No
Error No Yes
Query Acknowledgment Yes No
Query Parameter Definition Yes No
RSP_Q11.QUERY_RESULT_CLUSTER
Query Result Cluster group No No
Master File Entry Yes No
Location Identification Yes No
Location Characteristic No Yes
Location Relationship No Yes
RSP_Q11.MF_LOC_DEPT
Mf Loc Dept group Yes Yes
Location Department Yes No
Location Characteristic No Yes
Location Charge Code No Yes
Continuation Pointer No No

RSP_Q11 is an RSP segment-pattern response, but the local v2.5.1 structure here is more specific than the broad RSP_K11 example. After the acknowledgment and query status segments, it returns a location-style result cluster built around MFE, LOC, LCH, LRL, LDP, and LCC.

That makes this page best read as a local Q11 response profile for location or facility master data. For a generic row-oriented RSP response with RDF/RDT, use RSP_K11 instead.

A small RSP Q11 example

MSH|^~\&|FACILITYREG|CITYHOSP|PORTAL|CITYHOSP|20260717115000||RSP^Q11^RSP_Q11|RSPQ110001|P|2.5.1 MSA|AA|QBPQ110001 QAK|QLOC001|OK|Q11^Location lookup^HL7nnn|1|1|0 QPD|Q11^Location lookup^HL7nnn|QLOC001|CARD MFE|MAD|LOC-1001|20260717115000|CARD^^^CITYHOSP|PL LOC|CARD^2A^12^CITYHOSP|Cardiology clinic|CLINIC|City Hospital LCH|1|SERVICE^Service^L|CARD^Cardiology^L LDP|CARD^Cardiology department^L|AMB^Ambulatory^L|20260701000000 LCC|CARDVISIT^Cardiology visit charge^L|PROF^Professional fee^L

What workflow it represents

The requester asks for a location-related answer, and the receiver responds with the matching location master-file data. A portal, scheduling system, bed-management tool, or integration engine might use the returned location details to populate pick lists, validate routing decisions, or synchronize local reference data.

The first half of the message is still a query response. MSA acknowledges the original message control ID, QAK reports query status, and QPD echoes the query definition and tag.

How to read the structure

The optional RSP_Q11.QUERY_RESULT_CLUSTER is the business content. MFE identifies the master-file row and event, LOC identifies the location, LCH and LRL can qualify location characteristics and relationships, and the repeating department group adds LDP plus optional LCH and LCC details.

If no locations match, the receiver may still return a syntactically successful message with no result cluster. Read QAK for the query outcome instead of assuming that MSA-1 AA means data was found.

Implementation traps

The easy mistake is confusing message acceptance with query success. MSA tells you whether the response message accepted the original control ID. QAK tells you whether the query itself found data, found too much data, or failed application rules.

Another trap is treating location codes as display text. LOC, LDP, and LCC values usually feed routing, charging, scheduling, or operational rules, so changes should be versioned and coordinated like other master-file content.

Reference notes

HL7 terminology identifies RSP as a segment-pattern response. The local v2.5.1 RSP_Q11 structure contains MSH, optional SFT, MSA, optional ERR, QAK, QPD, an optional location-shaped query result cluster, and optional DSC.