
if exists (select* from sys.indexes i where i.[object_id] = object_id('AKUZ.T_NOTIFICATION_ABOUT_HOSPITAL', 'U') and i.name = 'IX_NOTIFICATION_ABOUT_HOSPITAL_Patient_EmergencyEvent_CreateDateTime')
	drop index IX_NOTIFICATION_ABOUT_HOSPITAL_Patient_EmergencyEvent_CreateDateTime ON AKUZ.T_NOTIFICATION_ABOUT_HOSPITAL
go
	CREATE INDEX IX_NOTIFICATION_ABOUT_HOSPITAL_Patient_EmergencyEvent_CreateDateTime ON [AKUZ].[T_NOTIFICATION_ABOUT_HOSPITAL] ([Patient], [EmergencyEvent], [CreateDateTime]) WITH (SORT_IN_TEMPDB = ON, FILLFACTOR = 95);
go

if exists (select* from sys.indexes i where i.[object_id] = object_id('AKUZ.T_NOTIFICATION_ABOUT_HOSPITAL', 'U') and i.name = 'IX_NOTIFICATION_ABOUT_HOSPITAL_OID2_Includes')
	drop index IX_NOTIFICATION_ABOUT_HOSPITAL_OID2_Includes ON AKUZ.T_NOTIFICATION_ABOUT_HOSPITAL
go
	CREATE INDEX [IX_NOTIFICATION_ABOUT_HOSPITAL_OID2_Includes] ON [AKUZ].[T_NOTIFICATION_ABOUT_HOSPITAL] ([OID2])  INCLUDE ([CardNumber], [Patient], [PatientUnidentified], [callReason], [diagnosisCode], [note], [cancelReasonDetail], [CancelPerson], [EmergencyEvent], [CreateDateTime], [ArriveTime]) WITH (SORT_IN_TEMPDB = ON, FILLFACTOR = 95);
go