if exists(select* from sys.indexes i where i.[object_id] = OBJECT_ID('AKUZ.T_MKF_DIAGNOSIS_RECORD', 'U') and i.name = 'IX_MKF_DIAGNOSIS_RECORD_MkfDiagnosis_Includes_20241028')
	drop index IX_MKF_DIAGNOSIS_RECORD_MkfDiagnosis_Includes_20241028 on AKUZ.T_MKF_DIAGNOSIS_RECORD;
go
	CREATE INDEX IX_MKF_DIAGNOSIS_RECORD_MkfDiagnosis_Includes_20241028 ON [AKUZ].[T_MKF_DIAGNOSIS_RECORD] ([MkfDiagnosis])  INCLUDE ([PostingDate], [type_]) WITH (FILLFACTOR=100, SORT_IN_TEMPDB=ON);
go
if exists(select* from sys.indexes i where i.[object_id] = OBJECT_ID('AKUZ.T_ROUTE_RECORD', 'U') and i.name = 'IX_ROUTE_RECORD_PerformerLpu_20241028')
	drop index IX_ROUTE_RECORD_PerformerLpu_20241028 on AKUZ.T_ROUTE_RECORD;
go
    CREATE INDEX IX_ROUTE_RECORD_PerformerLpu_20241028 ON [AKUZ].[T_ROUTE_RECORD] ([PerformerLpu])  WITH (FILLFACTOR=100, SORT_IN_TEMPDB=ON, MAXDOP = 0);
go
if exists(select* from sys.indexes i where i.[object_id] = OBJECT_ID('AKUZ.T_HOSPITAL_DESTINATION_LEK_COMPONENT', 'U') and i.name = 'IX_HOSPITAL_DESTINATION_LEK_COMPONENT_HospitalDestination_INCLUDE_20241028')
	drop index IX_HOSPITAL_DESTINATION_LEK_COMPONENT_HospitalDestination_INCLUDE_20241028 on AKUZ.T_HOSPITAL_DESTINATION_LEK_COMPONENT;
go
	CREATE INDEX IX_HOSPITAL_DESTINATION_LEK_COMPONENT_HospitalDestination_INCLUDE_20241028 ON [AKUZ].[T_HOSPITAL_DESTINATION_LEK_COMPONENT] ([HospitalDestination]) INCLUDE ([CMnn], [CTrn], [Procedure], [BaseComponent], [MedicationForms], [DoseCount], [DoseViewNew])   WITH (FILLFACTOR=100, SORT_IN_TEMPDB=ON);
go
if exists(select* from sys.indexes i where i.[object_id] = OBJECT_ID('AKUZ.T_HOSPITAL_DESTINATION', 'U') and i.name = 'IX_HOSPITAL_DESTINATION_MedicalExamination_20241028')
	drop index IX_HOSPITAL_DESTINATION_MedicalExamination_20241028 on AKUZ.T_HOSPITAL_DESTINATION;
go
	CREATE INDEX IX_HOSPITAL_DESTINATION_MedicalExamination_20241028 ON [AKUZ].[T_HOSPITAL_DESTINATION] ([MedicalExamination])  WITH (FILLFACTOR=100,SORT_IN_TEMPDB=ON, MAXDOP = 0);
go
