ADSM-L

Re: select query misbehaving?

2005-02-23 07:37:27
Subject: Re: select query misbehaving?
From: Jurjen Oskam <jurjen AT STUPENDOUS DOT ORG>
To: ADSM-L AT VM.MARIST DOT EDU
Date: Wed, 23 Feb 2005 13:21:44 +0059
On Wed, Feb 23, 2005 at 12:02:32PM -0000, Warren, Matthew (Retail) wrote:

> Ok, I can do that. But, surely NULL != 'VAULT' is not like '%VAULT%' ?

SQL has three valued logic: TRUE, FALSE and UNKNOWN (or NULL):

tsm: SERVER1>select count(*) from volumes

        108

tsm: SERVER1>select count(*) from volumes where pct_reclaim = 0.0

         36

tsm: SERVER1>select count(*) from volumes where pct_reclaim != 0.0

         53

tsm: SERVER1>select count(*) from volumes where pct_reclaim is null

         19

tsm: SERVER1>select count(*) from volumes where pct_reclaim is not null

         90

--
Jurjen Oskam
  "E-mail has just erupted like a weed, and instead of considering
  what to say when they write, people now just let thoughts drool
  out onto the screen." - R. Craig Hogan

<Prev in Thread] Current Thread [Next in Thread>