if not exists(SELECT 1 FROM sys.indexes WHERE [NAME] = 'IX_MOVEMENTS_DIVISION_CARD_Movement_RealDateIn_RealDateOut')
begin
    CREATE INDEX [IX_MOVEMENTS_DIVISION_CARD_Movement_RealDateIn_RealDateOut] ON [AKUZ].[T_MOVEMENTS_DIVISION_CARD] ( [Movement], [RealDateIn], [RealDateOut] )
end;

if not exists(SELECT 1 FROM sys.indexes WHERE [NAME] = 'IX_MOVEMENTS_DIVISION_CARD_Division_Includes')
begin
    CREATE INDEX [IX_MOVEMENTS_DIVISION_CARD_Division_Includes] ON [AKUZ].[T_MOVEMENTS_DIVISION_CARD] ([Division])  INCLUDE ([Movement], [RealDateIn], [RealDateOut] )
end;