select top 100 * from ClientSecurityReturnIndex where EffectiveDate=(select MAX(EffectiveDate) from ClientSecurityReturnIndex as tb where ClientSecurityId=ClientSecurityReturnIndex.ClientSecurityId)
select top 100 * from ClientSecurityReturnIndex where EffectiveDate=(select MAX(EffectiveDate) from ClientSecurityReturnIndex as tb where ClientSecurityId=ClientSecurityReturnIndex.ClientSecurityId)