How to know if my variable datetime is null?
<p>I'm trying to compare if my variable datetime is NULL, but it doesn't work, I'm new making comparising in SQL, so could someone said me how is the good way. This is my code:</p>

<pre><code>declare @FechaInicial datetime 
set @FechaInicial = (select FecharIncialDescarga 
                     from Contenedores where Id_Contenedor=@IdContenedor)

if(@FechaInicial = NULL) ---
    begin
    end
</code></pre>