Re: Query Help

From: Charles Hooper <>
Date: Wed, 16 Jan 2008 18:13:46 -0800 (PST)
Message-ID: <>

On Jan 16, 7:29 pm, (Doug Miller) wrote:
> In article <>, Charles Hooper <> wrote:
> >If you are famailar with BASIC programming, a similar construct might
> >look like this:
> > IF (AGE <> 65) OR (AGE =3D 65 AND RETIRED =3D "Y") THEN
> There's no point in examining AGE in the second clause.
> IF (AGE <> 65) OR (RETIRED = "Y") THEN
> has exactly the same effect.
> --
> Regards,
> Doug Miller (alphageek at milmac dot com)
> It's time to throw all their damned tea in the harbor again.

You are correct, I probably should have continued the discussion to simplify the pseudo code. However, my response was intentially constructed that way to demonstrate to the OP how one might translate a generic written requirement into basic pseudo code, and from there into a WHERE clause.

The OP wrote:
"I would like to find all instances where the Food_ID does not have a Cat_ID of 30 or has a Cat_ID of 30, but it is Inactive. In the example
shown above, I would see Food_ID of 302, but not 301."

Unfortunately, my pseudo code headed in the wrong direction, as pointed out in a later post by the OP.

Charles Hooper
IT Manager/Oracle DBA
K&M Machine-Fabricating, Inc. Received on Wed Jan 16 2008 - 20:13:46 CST

Original text of this message