I have one question regarding include column in the indexes. If I have an include column which is updating its value quite often, does it update the index every time it's updating the value or does the index only update when key columns are updating? Does include column updates add performance issues? According the example below, if the Balance and DiscountedAmount keep updating does it update the index IX_Temp_RegistrationNumber for every updates?
CREATE TABLE #Temp (
TheID BIGINT
,RegistrationNumber BIGINT
,ClientName VARCHAR(50)
,Balance NUMERIC(10, 2)
,DiscountedAmount NUMERIC(10, 2)
)
CREATE NONCLUSTERED INDEX [IX_Temp_RegistrationNumber] ON [#Temp] ([RegistrationNumber] ASC) INCLUDE (
[Balance]
,[DiscountedAmount]
)
GO