Save data to variable and use it in stored procedure
SELECT CASE WHEN T.Date IS NULL THEN M.TEXT ELSE T.TEXT END TEXT
     FROM (SELECT TOP(1) *
              FROM MyTable
          ORDER BY Date DESC) M
LEFT JOIN MyTable T ON T.Date&gt;= @userDate11


This is one of several ways to solve the problem.  The TOP(1) and ORDER BY Date DESC gives you the fallback record.  The original table aliased T is consigned as the optional partner in the LEFT JOIN.  This allows it to return no records, while still retaining the singular record from the derived table aliased M. The CASE statement then tests to see if we actually managed to get anything from T using WHEN T.Date IS NULL - if T is not empty, all the TEXT values will come from T, otherwise we will have just the single TEXT value from M, being the one for the MAX(Date).