Stored Procedure:-
CREATE PROCEDURE [dbo].[RT_SelectAll_BatchHistory_By_SchedulerTime]
@Skip INT,
@Take INT,
@ResultCode AS INT = 0 OUTPUT,
@ResultText AS VARCHAR(50)=NULL OUTPUT
AS
BEGIN
SET NOCOUNT ON;
BEGIN TRY
SELECT
[SchedulerTime]
,[ExecutedOn]
,[FinishedOn]
FROM [T_Scheduler] WITH(NOLOCK)
WHERE [IsActive] = 1
ORDER BY [SchedulerID]
OFFSET @Skip ROWS
FETCH NEXT @Take ROWS ONLY
SET @ResultCode = 0
SET @ResultText='SUCCESS'
END TRY
BEGIN CATCH
SET @ResultCode = -1
SET @ResultText='ERROR'
END CATCH
END
In this Stored procedure want to select All rows from SchedulerTime column and Null values From executedOn and finishedOn.
how can achieve this condition?