• Is this what you are expecting?

    SELECT a.customer, a.status, DATEDIFF(dd, a.mlastupdt, getdate()) AS NumDays

    FROM (SELECT Customer, max(LastUpdateDate) AS mlastupdt, [Status], createddate

    FROM #TempTable

    GROUP BY Customer, [Status], createddate) a

    ORDER BY a.Customer, a.[Status]