Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

I am trying to check if the date field is null in my database. I tried to check using the operators eq and ne but did not seem to work. It is a date time field in DB. I tried == did not work...... != seems to be working though... Do I have to do any manipulations?

Replies are listed 'Best First'.
Re: Check if Date is null
by japhy (Canon) on Jun 14, 2006 at 20:24 UTC
    In SQL, you'd write DateField IS NULL. In Perl, that NULL value is represented by undef, so you'd write not defined($DateField).

    Jeff japhy Pinyan, P.L., P.M., P.O.D, X.S.: Perl, regex, and perl hacker
    How can we ever be the sold short or the cheated, we who for every service have long ago been overpaid? ~~ Meister Eckhart