diff --git a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/dstu3/JpaValidationSupportDstu3.java b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/dstu3/JpaValidationSupportDstu3.java index 6017984820c..e1a248cad0a 100644 --- a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/dstu3/JpaValidationSupportDstu3.java +++ b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/dao/dstu3/JpaValidationSupportDstu3.java @@ -93,6 +93,9 @@ public class JpaValidationSupportDstu3 implements IJpaValidationSupportDstu3 { if ("ValueSet".equals(resourceName)) { if (localReference) { search = myValueSetDao.search(IAnyResource.SP_RES_ID, new StringParam(theUri)); + if (search.size() == 0) { + search = myValueSetDao.search(ValueSet.SP_URL, new UriParam(theUri)); + } } else { search = myValueSetDao.search(ValueSet.SP_URL, new UriParam(theUri)); }