UFN_FUZZYDATE_GETDATE

This function returns the fuzzy date given its ID.

Return

Return Type
datetime

Parameters

Parameter Parameter Type Mode Description
@ID uniqueidentifier IN

Definition

Copy


create function dbo.UFN_FUZZYDATE_GETDATE
    (@ID uniqueidentifier) 
    returns datetime 
as
begin
    declare @ACTUALDATE datetime = null;

    select @ACTUALDATE =
        case when @ID = 'EBBB508E-5670-45C7-9A67-E18B4E800023' then getdate() --Today

                 else null
        end;

    return @ACTUALDATE;
end