I used to remember this formula, for some reason I can't remember it. In SQL it's like this
Anyone have a solution for this. I am writing this in a PowerPivot calculated field but the logic should be the same.
HTML:
where s.StartDate = (select max(s1.StartDate) from [Server].[dbo].[Table] as s1 where s1.ID = s.ID and s1.CircEff <= getdate () )