Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id 5C04E1337B61 for ; Tue, 10 May 2011 17:33:35 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 00224-05 for ; Tue, 10 May 2011 20:33:17 +0000 (UTC) Received: from mx1.hub.org (mx1.hub.org [200.46.208.106]) by mail.postgresql.org (Postfix) with ESMTP id 70D7B1337990 for ; Tue, 10 May 2011 17:33:17 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-pw0-f46.google.com (mail-pw0-f46.google.com [209.85.160.46]) by mx1.hub.org (Postfix) with ESMTP id EA6993261CCF for ; Tue, 10 May 2011 20:33:16 +0000 (UTC) Received: by pwi15 with SMTP id 15so2986843pwi.19 for ; Tue, 10 May 2011 13:33:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:subject:mime-version:content-type:from :in-reply-to:date:cc:content-transfer-encoding:message-id:references :to:x-mailer; bh=jwNdxCFmjyI0aWUPQzlYA4EicSY4BrqCRxdXJ36oK2Q=; b=N2axmKCYGhwArGuHupgdW4IbgiL19s20Gngzto/qQIrUYpmx3rRZIQl03x0wHFDfcx BHj1y/fFTmFkrmN0l66d0iLAn3+U4xrNSglndQ0CP2m0IvnDA+JetW8hl6BTEET1yVW7 ZGD3Mm6Etb6zVuqlVKJ7Y6IPrrkM1RqifBwWI= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=subject:mime-version:content-type:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to:x-mailer; b=vsmS5xrqfQfOEKHI+ocYkRXiV+VeiyNFZbTgrWK40T3IcgeuemWcY/qcwgWNX6rnzA NYlzG2+O5RF3Wig6wYB7c4lh9Wt+Xj2Qlo5B37HnVnpQEmZtGpI9/Jx+iuHFAqy4JNm5 yHfaKKVCbA+E02eC7P6qpuKGObgU/+xqXWHz8= Received: by 10.68.28.133 with SMTP id b5mr1105234pbh.264.1305059596232; Tue, 10 May 2011 13:33:16 -0700 (PDT) Received: from [10.9.73.20] (173-164-88-9-Oregon.hfc.comcastbusiness.net [173.164.88.9]) by mx.google.com with ESMTPS id p2sm5022873pbq.6.2011.05.10.13.33.14 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 10 May 2011 13:33:14 -0700 (PDT) Subject: Re: Dates and NULL's` Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: text/plain; charset=us-ascii From: Brent Dombrowski In-Reply-To: <201105100948.41392.johnf@jfcomputer.com> Date: Tue, 10 May 2011 13:33:12 -0700 Cc: pgsql-sql@postgresql.org Content-Transfer-Encoding: quoted-printable Message-Id: <7E925851-8A86-4922-87D4-88F37F86C101@gmail.com> References: <201105100948.41392.johnf@jfcomputer.com> To: John Fabiani X-Mailer: Apple Mail (2.1084) X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.898 tagged_above=-5 required=5 tests=BAYES_00=-1.9, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RFC_ABUSE_POST=0.001 X-Spam-Level: X-Archive-Number: 201105/72 X-Sequence-Number: 35356 On May 10, 2011, at 9:48 AM, John Fabiani wrote: > Hi, > Maybe this is a dumb question but if I have a date field that contains = a NULL=20 > will it show up when I ask for a where date range for the same date = field. >=20 > Where mydate >=3D "2011/04/01"::date and mydate<=3D "2011/04/30"::date >=20 > With the above where will the NULL's be selected???? >=20 > I ask because I was always told that a NULL matches everything and = nothing! >=20 > Johnf >=20 > --=20 > Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org) > To make changes to your subscription: > http://www.postgresql.org/mailpref/pgsql-sql The NULLs will not be included. NULL matches nothing, not even itself. Brent D.