diff --git a/hapi-fhir-jpa/src/main/java/ca/uhn/fhir/jpa/util/TestUtil.java b/hapi-fhir-jpa/src/main/java/ca/uhn/fhir/jpa/util/TestUtil.java index 5ad9410b772..0a01ccd0719 100644 --- a/hapi-fhir-jpa/src/main/java/ca/uhn/fhir/jpa/util/TestUtil.java +++ b/hapi-fhir-jpa/src/main/java/ca/uhn/fhir/jpa/util/TestUtil.java @@ -85,7 +85,8 @@ public class TestUtil { "FK_CONCEPTDESIG_CONCEPT", "FK_TERM_CONCEPTPC_CHILD", "FK_TERM_CONCEPTPC_PARENT", - "FK_TRM_VALUESET_CONCEPT_PID" + "FK_TRM_VALUESET_CONCEPT_PID", + "FK_SEARCHINC_SEARCH" ); diff --git a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/entity/SearchInclude.java b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/entity/SearchInclude.java index 461aa74825d..495748c6c1c 100644 --- a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/entity/SearchInclude.java +++ b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/entity/SearchInclude.java @@ -37,7 +37,7 @@ import javax.persistence.Table; //@formatter:off @Entity @Table(name = "HFJ_SEARCH_INCLUDE", indexes = { - @Index(name = "IDX_HFJ_SEARCH_INCLUDE_SRCHPID", columnList = "SEARCH_PID") + @Index(name = "FK_SEARCHINC_SEARCH", columnList = "SEARCH_PID") }) //@formatter:on public class SearchInclude implements Serializable { diff --git a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/migrate/tasks/HapiFhirJpaMigrationTasks.java b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/migrate/tasks/HapiFhirJpaMigrationTasks.java index 054991caff5..19f8e9668a2 100644 --- a/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/migrate/tasks/HapiFhirJpaMigrationTasks.java +++ b/hapi-fhir-jpaserver-base/src/main/java/ca/uhn/fhir/jpa/migrate/tasks/HapiFhirJpaMigrationTasks.java @@ -103,10 +103,11 @@ public class HapiFhirJpaMigrationTasks extends BaseMigrationTasks { // Add new Index to HFJ_SEARCH_INCLUDE on SEARCH_PID version .onTable("HFJ_SEARCH_INCLUDE") - .addIndex("20221207.1", "IDX_HFJ_SEARCH_INCLUDE_SRCHPID") + .addIndex("20221207.1", "FK_SEARCHINC_SEARCH") .unique(false) .online(true) - .withColumns("SEARCH_PID"); + .withColumns("SEARCH_PID") + .onlyAppliesToPlatforms(NON_AUTOMATIC_FK_INDEX_PLATFORMS); } private void init620() {