Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revinclude is case sensitive #173

Open
Andrzej-Pietrzak opened this issue Mar 15, 2017 · 0 comments
Open

Revinclude is case sensitive #173

Andrzej-Pietrzak opened this issue Mar 15, 2017 · 0 comments

Comments

@Andrzej-Pietrzak
Copy link

Andrzej-Pietrzak commented Mar 15, 2017

We're seeing _revinclude behave differently then _include, when references contain id's with uppercase characters the revinclude search doesn't find them.

For the following searches, the one the differences between results in upper case uuid's and lowercase uuid's, similarly for text identifiers:

SELECT fhir_create_resource('{"allowId": true, "resource": {"id":"fosterfamilypractice","name":"Foster Family Practice","identifier":[{"value":"FosterFamilyPractice","system":"urn:ietf:rfc:3986","assigner":{"display":"epicCare","reference":"Organization/09ab4028-5c1b-40c9-9666-3fa67fb784s2"}}],"resourceType":"Organization"}}');
SELECT fhir_create_resource('{"allowId": true, "resource": {"id":"54e57a7f-a57a-411f-bd5a-82134b79117b","name":"Neurology Unit","status":"active","resourceType":"Location","managingOrganization":{"display":"Foster Family Practice","reference":"Organization/fosterfamilypractice"}}}');

SELECT fhir_create_resource('{"allowId": true, "resource": {"id":"PiersFamilyPractice","name":"Piers Family Practice","identifier":[{"value":"PiersFamilyPractice","system":"urn:ietf:rfc:3986","assigner":{"display":"epicCare","reference":"Organization/09ab4028-5c1b-40c9-9666-3fa67fb784s2"}}],"resourceType":"Organization"}}');
SELECT fhir_create_resource('{"allowId": true, "resource": {"id":"location674","name":"Cardiology Unit","status":"active","resourceType":"Location","managingOrganization":{"display":"Piers Family Practice","reference":"Organization/PiersFamilyPractice"}}}');

SELECT fhir_create_resource('{"allowId": true, "resource": {"id":"EDF694FD-4CB0-46A6-B9AC-95D5AC7E9E02","name":"Erickson Family Practice","identifier":[{"value":"EricksonFamilyPractice","system":"urn:ietf:rfc:3986","assigner":{"display":"epicCare","reference":"Organization/09ab4028-5c1b-40c9-9666-3fa67fb784s2"}}],"resourceType":"Organization"}}');
SELECT fhir_create_resource('{"allowId": true, "resource": {"id":"1234","name":"Dermatology Unit","status":"active","resourceType":"Location","managingOrganization":{"display":"Erickson Family Practice","reference":"Organization/EDF694FD-4CB0-46A6-B9AC-95D5AC7E9E02"}}}');

SELECT fhir_create_resource('{"allowId": true, "resource": {"id":"c38183a4-ec1c-4f2b-b350-a09bde110398","name":"Simons Family Practice","identifier":[{"value":"SimonsFamilyPractice","system":"urn:ietf:rfc:3986","assigner":{"display":"epicCare","reference":"Organization/09ab4028-5c1b-40c9-9666-3fa67fb784s2"}}],"resourceType":"Organization"}}');
SELECT fhir_create_resource('{"allowId": true, "resource": {"id":"Location754","name":"Nephrology Unit","status":"active","resourceType":"Location","managingOrganization":{"display":"Simons Family Practice","reference":"Organization/c38183a4-ec1c-4f2b-b350-a09bde110398"}}}');

--

SELECT fhir_search('{"resourceType": "Organization", "queryString": "_id=fosterfamilypractice&_revinclude=Location:organization"}'); -- ok, got both
SELECT fhir_search('{"resourceType": "Location", "queryString": "_id=54e57a7f-a57a-411f-bd5a-82134b79117b&_include=organization"}'); -- ok, got both

SELECT fhir_search('{"resourceType": "Organization", "queryString": "_id=c38183a4-ec1c-4f2b-b350-a09bde110398&_revinclude=Location:organization"}');  -- ok, got both
SELECT fhir_search('{"resourceType": "Location", "queryString": "_id=Location754&_include=organization"}'); -- ok, got both

SELECT fhir_search('{"resourceType": "Organization", "queryString": "_id=PiersFamilyPractice&_revinclude=Location:organization"}'); -- nok, missing location
SELECT fhir_search('{"resourceType": "Location", "queryString": "_id=location674&_include=organization"}'); -- ok, got both

SELECT fhir_search('{"resourceType": "Organization", "queryString": "_id=EDF694FD-4CB0-46A6-B9AC-95D5AC7E9E02&_revinclude=Location:organization"}');  -- nok, missing location
SELECT fhir_search('{"resourceType": "Location", "queryString": "_id=Location754&_include=organization"}'); -- ok, got both

@Andrzej-Pietrzak Andrzej-Pietrzak changed the title Revinclude is case sensitivite Revinclude is case sensitive Mar 15, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant