Query+for+Docs+Page+4

= 4. Error Handling = Error codes used in the Query for Documents interface will conform to the error codes listed in IHE TF Volume 3 Section 4.1.13. The error codes relevant to the Stored Query are listed in the following table:
 * ** Error Code ** || ** Description ** ||
 * XDSRegistryError || Error from the registry in processing the query (eg. invalid query criteria) ||
 * XDSRegistryBusy || Too much activity ||
 * XDSRegistryOutOfResources || Resources are low. ||
 * XDSTooManyResults ||  ||
 * XDSUnknownStoredQuery || The Query ID provided in the request is not recognized. ||
 * XDSStoredQueryMissingParam || A required parameter to a stored query is missing. ||
 * XDSStoredQueryParamNumber || A parameter which only accepts a single value is coded with multiple values ||
 * XDSUnknownPatientId || The Patient ID specified is no longer valid. If the Patient ID is not known, has never been valid, and the HIE is not able to distinguish this from previously valid Patient ID’s then this error should also be returned. Otherwise a Patient ID that has never been valid should result in an empty list. ||
 * XDSUnknownCommunity || A value for the homeCommunityId is not recognized ||
 * XDSMissingHomeCommunityId || A value for the homeCommunityId is required and has not been specified ||

= 5 Auditing =

Both the Initiating Gateway and Responding Gateway shall audit the Cross Gateway Query as described in Section 3.38.4.1.4 in the XCA Supplement. //This section of the supplement is copied below for reference only. Please consult the current XCA supplement to ensure the latest version is being used.//

**3.38.4.1.4 Security Considerations** Both the Initiating Gateway and Responding Gateway shall audit the Cross Gateway Query. The audit entries shall be equivalent to the entries required for the Registry Stored Query.

The Initiating Gateway: · If receiving a Registry Stored Query transaction from a Document Consumer, shall audit as if 1130 it were a Document Registry. See ITI TF-2a: 3.18.4.2.5. · In addition, shall audit the Cross Gateway Query as if it were a Document Consumer except that for EventTypeCode the Initiating Gateway shall specify EV(“ITI-38”, “IHE Transactions”, and “Cross Gateway Query”). See ITI TF-2a: 3.18.4.2.4. · In addition, if interacting with a local Document Registry, shall audit as if it were a 1135 Document Consumer. See ITI TF-2a: 3.18.4.2.5.

The Responding Gateway: · Shall audit the Cross Gateway Query as if it were a Document Registry except that for EventTypeCode the Responding Gateway shall specify EV (“ITI-38”, “IHE Transactions”, “Cross Gateway Query”). See ITI TF-2a: 3.18.4.2.4. · In addition, if interacting with a local Document Registry, shall audit as if it were a Document Consumer. See ITI TF-2a: 3.18.4.2.5.

= Appendix A: Sample Messages  = The samples in the following two sections show a typical SOAP request and its relative SOAP response. The sample messages also show the WS-Addressing headers , , …; these WS-Addressing headers are populated according to the W3C WS-Addressing standard.

All of the samples presented in this section are also available online on the IHE FTP site at ftp://ftp.ihe.net/TF_Implementation_Material/ITI/packages/.

= Sample Cross Gateway Query SOAP Request =   urn:ihe:iti:2007:CrossGatewayQuery urn:uuid:def119ad-dc13-49c1-a3c7-e3742531f9b3  http://www.w3.org/2005/08/addressing/anonymous  http://localhost/service/IHEXCARespondingGateway.svc  <s:Body> <query:AdhocQueryRequest xmlns:query="urn:oasis:names:tc:ebxml-regrep:xsd:query:3.0" xmlns:rim="urn:oasis:names:tc:ebxml-regrep:xsd:rim:3.0"> <query:ResponseOption returnComposedObjects="true" returnType="LeafClass"/> <rim:AdhocQuery id="urn:uuid:14d4debf-8f97-4251-9a74-a90016b0af0d"> <rim:Slot name="$XDSDocumentEntryPatientId"> <rim:ValueList> <Value>'d8420442513945d^^^&amp;1.3.6.1.4.1.21367.2005.1.1&amp;ISO'</Value> </rim:ValueList> </rim:Slot> <rim:Slot name="$XDSDocumentEntryStatus"> <rim:ValueList> <rim:Value>('urn:oasis:names:tc:ebxml-regrep:StatusType:Approved', ‘urn:ihe:iti:2010:StatusType:DeferredCreation’)</Value> </rim:ValueList> </rim:Slot> </query:AdhocQuery> </query:AdhocQueryRequest> </s:Body>

Sample Response

<s:Envelope xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:a="http://www.w3.org/2005/08/addressing">  <a:Action s:mustUnderstand="1">urn:ihe:iti:2007:CrossGatewayQueryResponse</a:Action> <a:RelatesTo>urn:uuid:def119ad-dc13-49c1-a3c7-e3742531f9b3</a:RelatesTo> </s:Header> <s:Body> <AdhocQueryResponse xmlns:query="urn:oasis:names:tc:ebxml-regrep:xsd:query:3.0" xmlns:rim="urn:oasis:names:tc:ebxml-regrep:xsd:rim:3.0" status="Success"> <rim:RegistryObjectList> <rim:ExtrinsicObject id="urn:uuid:08a15a6f-5b4a-42de-8f95-89474f83abdf" isOpaque="false" mimeType="text/xml" objectType="urn:uuid:7edca82f-054d-47f2-a032-9b2a5b5186c1" status="urn:oasis:names:tc:ebxml-regrep:StatusType:Approved" home="urn:oid: 2.16.840.1.113883.3.166"> <rim:ExtrinsicObject home=“urn:oid: 2.16.840.1.113883.3.166” id="urn:uuid:7b3f363f-0465-4bc0-bdb3-bb72657284ca" isOpaque="false" lid="urn:uuid:7b3f363f-0465-4bc0-bdb3-bb72657284ca" mimeType="text/xml" objectType="urn:uuid:7edca82f-054d-47f2-a032-9b2a5b5186c1" status="urn:oasis:names:tc:ebxml-regrep:StatusType:Approved"> <rim:Slot name="URI"> <rim:ValueList> <rim:Value>http://111.111.11.11:2011/IB/servlet/runHXML?IBSite=ihetest& IBThread=repo_query&doc_id=df7e998e-fc53-4a51-61a0-b31293b046c7</rim:Value> </rim:ValueList> </rim:Slot> <rim:Slot name="creationTime"> <rim:ValueList> <rim:Value>20080516</rim:Value> </rim:ValueList> </rim:Slot> <rim:Slot name="hash"> <ValueList> <Value>fcd7410538d3ae5a69b5d6d6b7e97b2252191328</rim:Value> </rim:ValueList> </rim:Slot> <rim:Slot name="languageCode"> <rim:ValueList> <rim:Value>en-us</rim:Value> </rim:ValueList> </rim:Slot> <rim:Slot name="repositoryUniqueId"> <rim:ValueList> <rim:Value>2.16.840.1.113883.3.166.3.1</rim:Value> </rim:ValueList> </rim:Slot> <rim:Slot name="serviceStartTime"> <rim:ValueList> <rim:Value>200805150800</rim:Value> </rim:ValueList> </rim:Slot> <rim:Slot name="serviceStopTime"> <rim:ValueList> <rim:Value>200805151001</rim:Value> </rim:ValueList> </rim:Slot> <rim:Slot name="size"> <rim:ValueList> <rim:Value>35452</rim:Value> </rim:ValueList> </rim:Slot> <rim:Slot name="sourcePatientId"> <rim:ValueList> <rim:Value>NISTTEST12^^^&2.16.840.1.113883.1.166.1.2&ISO</rim:Value> </rim:ValueList> </rim:Slot> <rim:Slot name="sourcePatientInfo"> <rim:ValueList> <rim:Value>PID-3|pid1^^^domain</rim:Value> <rim:Value>PID-5|Schnur^Anna^^^</rim:Value> <rim:Value>PID-7|19560813</rim:Value> <rim:Value>PID-8|F</rim:Value> <rim:Value>PID-11|1 King Street NW^^Abingdon^VA^24210^USA</rim:Value> </rim:ValueList> </rim:Slot> <rim:Name> <rim:LocalizedString charset="UTF-8" value="Physical Test" xml:lang="en-us" /> </rim:Name> <rim:Description /> <rim:VersionInfo versionName="1.1" /> <rim:Classification classificationScheme="urn:uuid:93606bcf-9494-43ec-9b4e-a7748d1a838d" classifiedObject="urn:uuid:7b3f363f-0465-4bc0-bdb3-bb72657284ca" home=“urn:oid: 2.16.840.1.113883.3.166” id="urn:uuid:541d7892-0391-4af0-abf0-cf4c30628f37" lid="urn:uuid:541d7892-0391-4af0-abf0-cf4c30628f37" nodeRepresentation="" objectType="urn:oasis:names:tc:ebxml-regrep:ObjectType:RegistryObject:Classification"> <rim:Slot name="authorInstitution"> <rim:ValueList> <rim:Value>Adult Clinic</rim:Value> <rim:Value>Beach Community Medical</rim:Value> </rim:ValueList> </rim:Slot> <rim:Slot name="authorPerson"> <rim:ValueList> <rim:Value>^Hamilton^Greg^^^</rim:Value> </rim:ValueList> </rim:Slot> <rim:Slot name="authorRole"> <rim:ValueList> <rim:Value>Chief Internist</rim:Value> </rim:ValueList> </rim:Slot> <rim:Slot name="authorSpecialty"> <rim:ValueList> <rim:Value>Pulmonary Specialist</rim:Value> </rim:ValueList> </rim:Slot> <rim:Name /> <rim:Description /> <rim:VersionInfo versionName="1.1" /> </rim:Classification> <rim:Classification classificationScheme="urn:uuid:93606bcf-9494-43ec-9b4e-a7748d1a838d" classifiedObject="urn:uuid:7b3f363f-0465-4bc0-bdb3-bb72657284ca" home=“urn:oid: 2.16.840.1.113883.3.166” id="urn:uuid:9f602797-f9d0-4ce9-a02c-a45770aebee5" lid="urn:uuid:9f602797-f9d0-4ce9-a02c-a45770aebee5" nodeRepresentation="" objectType="urn:oasis:names:tc:ebxml-regrep:ObjectType:RegistryObject:Classification"> <rim:Slot name="authorInstitution"> <rim:ValueList> <rim:Value>Caring For Adults Clinic</rim:Value> <rim:Value>Raceway Medical Community</rim:Value> </rim:ValueList> </rim:Slot> <rim:Slot name="authorPerson"> <rim:ValueList> <rim:Value>^Stewart^Chris^^^</rim:Value> </rim:ValueList> </rim:Slot> <rim:Slot name="authorRole"> <rim:ValueList> <rim:Value>Department Head</rim:Value> </rim:ValueList> </rim:Slot> <rim:Slot name="authorSpecialty"> <rim:ValueList> <rim:Value>Teaching Professor</rim:Value> </rim:ValueList> </rim:Slot> <rim:Name /> <rim:Description /> <rim:VersionInfo versionName="1.1" /> </rim:Classification> <rim:Classification classificationScheme="urn:uuid:41a5887f-8865-4c09-adf7-e362475b143a" classifiedObject="urn:uuid:7b3f363f-0465-4bc0-bdb3-bb72657284ca" home=“urn:oid: 2.16.840.1.113883.3.166” id="urn:uuid:22dbab5f-f2ef-471c-8a71-920c5e2bbc6a" lid="urn:uuid:22dbab5f-f2ef-471c-8a71-920c5e2bbc6a" nodeRepresentation="34133-9" objectType="urn:oasis:names:tc:ebxml-regrep:ObjectType:RegistryObject:Classification"> <rim:Slot name="codingScheme"> <rim:ValueList> <rim:Value>2.16.840.1.113883.6.1</rim:Value> </rim:ValueList> </rim:Slot> <rim:Name> <rim:LocalizedString charset="UTF-8" value="SUMMARIZATION OF EPISODE NOTE" xml:lang="en-us" /> </rim:Name> <rim:Description /> <rim:VersionInfo versionName="1.1" /> </rim:Classification> <rim:Classification classificationScheme="urn:uuid:f4f85eac-e6cb-4883-b524-f2705394840f" classifiedObject="urn:uuid:7b3f363f-0465-4bc0-bdb3-bb72657284ca" home=“urn:oid: 2.16.840.1.113883.3.166” id="urn:uuid:c016bcbf-2a8b-4140-8dfc-e8ca1215a960" lid="urn:uuid:c016bcbf-2a8b-4140-8dfc-e8ca1215a960" nodeRepresentation="N" objectType="urn:oasis:names:tc:ebxml-regrep:ObjectType:RegistryObject:Classification"> <rim:Slot name="codingScheme"> <rim:ValueList> <rim:Value>2.16.840.1.113883.5.25</rim:Value> </rim:ValueList> </rim:Slot> <rim:Name> <rim:LocalizedString charset="UTF-8" value="Normal" xml:lang="en-us" /> </rim:Name> <rim:Description /> <rim:VersionInfo versionName="1.1" /> </rim:Classification> <rim:Classification classificationScheme="urn:uuid:a09d5840-386c-46f2-b5ad-9c3699a4309d" classifiedObject="urn:uuid:7b3f363f-0465-4bc0-bdb3-bb72657284ca" home=“urn:oid: 2.16.840.1.113883.3.166” id="urn:uuid:220e5350-de61-4955-b253-cb7d5a71f846" lid="urn:uuid:220e5350-de61-4955-b253-cb7d5a71f846" nodeRepresentation="2.16.840.1.113883.10.20.1" objectType="urn:oasis:names:tc:ebxml-regrep:ObjectType:RegistryObject:Classification"> <rim:Slot name="codingScheme"> <rim:ValueList> <rim:Value>Connect-a-thon formatCodes</rim:Value> </rim:ValueList> </rim:Slot> <rim:Name> <rim:LocalizedString charset="UTF-8" value="HL7 CCD Document" xml:lang="en-us" /> </rim:Name> <rim:Description /> <rim:VersionInfo versionName="1.1" /> </rim:Classification> <rim:Classification classificationScheme="urn:uuid:f33fb8ac-18af-42cc-ae0e-ed0b0bdb91e1" classifiedObject="urn:uuid:7b3f363f-0465-4bc0-bdb3-bb72657284ca" home=“urn:oid: 2.16.840.1.113883.3.166” id="urn:uuid:b2b47841-a48a-4a6c-8713-ff1b3ce202ed" lid="urn:uuid:b2b47841-a48a-4a6c-8713-ff1b3ce202ed" nodeRepresentation="HOSP" objectType="urn:oasis:names:tc:ebxml-regrep:ObjectType:RegistryObject:Classification"> <rim:Slot name="codingScheme"> <rim:ValueList> <rim:Value>2.16.840.1.113883.5.111</rim:Value> </rim:ValueList> </rim:Slot> <rim:Name> <rim:LocalizedString charset="UTF-8" value="Hospital" xml:lang="en-us" /> </rim:Name> <rim:Description /> <rim:VersionInfo versionName="1.1" /> </rim:Classification> <rim:Classification classificationScheme="urn:uuid:cccf5598-8b07-4b77-a05e-ae952c785ead" classifiedObject="urn:uuid:7b3f363f-0465-4bc0-bdb3-bb72657284ca" home=“urn:oid: 2.16.840.1.113883.3.166” id="urn:uuid:3ba60301-14e1-45f7-b1cb-9cda2ee96032" lid="urn:uuid:3ba60301-14e1-45f7-b1cb-9cda2ee96032" nodeRepresentation="394802001" objectType="urn:oasis:names:tc:ebxml-regrep:ObjectType:RegistryObject:Classification"> <rim:Slot name="codingScheme"> <rim:ValueList> <rim:Value>2.16.840.1.113883.6.96</rim:Value> </rim:ValueList> </rim:Slot> <rim:Name> <rim:LocalizedString charset="UTF-8" value="General Medicine" xml:lang="en-us" /> </rim:Name> <rim:Description /> <rim:VersionInfo versionName="1.1" /> </rim:Classification> <rim:Classification classificationScheme="urn:uuid:f0306f51-975f-434e-a61c-c59651d33983" classifiedObject="urn:uuid:7b3f363f-0465-4bc0-bdb3-bb72657284ca" home=“urn:oid: 2.16.840.1.113883.3.166” id="urn:uuid:92989021-5243-40de-9100-c0f509241839" lid="urn:uuid:92989021-5243-40de-9100-c0f509241839" nodeRepresentation="34133-9" objectType="urn:oasis:names:tc:ebxml-regrep:ObjectType:RegistryObject:Classification"> <rim:Slot name="codingScheme"> <rim:ValueList> <rim:Value>2.16.840.1.113883.6.1</rim:Value> </rim:ValueList> </rim:Slot> <rim:Name> <rim:LocalizedString charset="UTF-8" value="SUMMARIZATION OF EPISODE NOTE" xml:lang="en-us" /> </rim:Name> <rim:Description /> <rim:VersionInfo versionName="1.1" /> </rim:Classification> <rim:ExternalIdentifier home=“urn:oid: 2.16.840.1.113883.3.166” id="urn:uuid:1a27b62c-c508-4713-b1e5-aec138b93af2" identificationScheme="urn:uuid:58a6f841-87b3-4a3e-92fd-a8ffeff98427" lid="urn:uuid:1a27b62c-c508-4713-b1e5-aec138b93af2" objectType="urn:oasis:names:tc:ebxml-regrep:ObjectType:RegistryObject:ExternalIdentifier" registryObject="urn:uuid:7b3f363f-0465-4bc0-bdb3-bb72657284ca" value="338275^^^&2.16.840.1.113883.3.166.1.1&ISO"> <rim:Name> <rim:LocalizedString charset="UTF-8" value="XDSDocumentEntry.patientId" xml:lang="en-us" /> </rim:Name> <rim:Description /> <rim:VersionInfo versionName="1.1" /> </rim:ExternalIdentifier> <rim:ExternalIdentifier home=“urn:oid: 2.16.840.1.113883.3.166” id="urn:uuid:b1f8a6fc-7537-464d-bd09-dfab13853293" identificationScheme="urn:uuid:2e82c1f6-a085-4c72-9da3-8640a32e42ab" lid="urn:uuid:b1f8a6fc-7537-464d-bd09-dfab13853293" objectType="urn:oasis:names:tc:ebxml-regrep:ObjectType:RegistryObject:ExternalIdentifier" registryObject="urn:uuid:7b3f363f-0465-4bc0-bdb3-bb72657284ca" value="129.6.58.92.147"> <rim:Name> <rim:LocalizedString charset="UTF-8" value="XDSDocumentEntry.uniqueId" xml:lang="en-us" /> </rim:Name> <rim:Description /> <rim:VersionInfo versionName="1.1" /> </rim:ExternalIdentifier> </rim:ExtrinsicObject> </rim:RegistryObjectList> </AdhocQueryResponse> </s:Body> </s:Envelope>

Note: The AdhocQuery/@id 14d4debf-8f97-4251-9a74-a90016b0af0d is a well known constant which stands for the FindDocuments query. The ITI-18 specification lists about a dozen different such ad hoc query types that shall be used here. The FindDocuments query finds documents (XDSDocumentEntry objects) for a given patientID with a matching ‘status’ attribute. The other parameters can be used to restrict the set of XDSDocumentEntry objects returned. = Appendix B: WSDL  = IHE provides example WSDL definitions for the Responding Gateway actor supporting the Cross Gateway Query Transaction. The WSDL, as well as schema and examples, can be accessed at []XCA.Support.Materials.v5.zip Note: this version of the materials includes changes resulting from IHE Change Proposal 420 which is adopted by this specification. ** Previous PageHome Page **