Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Query Help

Query Help

From: <cnbland1_at_juno.com>
Date: Fri, 21 Dec 2007 09:48:07 -0800 (PST)
Message-ID: <4b6db6b0-b14c-46cf-859a-3255214302ef@p69g2000hsa.googlegroups.com>


I am a beginning Oracle 9i user and I was hoping that someone can help me. I think I have the basic SQL statements down pat, but this problem is a little too advanced for me.

Let's say that I have Table A with the following columns: Food_ID, Descr, Cat_ID and Status. Here are some sample rows in the table: 301 Apple 10 Active
301 Ham 20 Inactive
301 Carrot 30 Active
302 Orange 10 Inactive
302 Balony 20 Active

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.

Thank you, Received on Fri Dec 21 2007 - 11:48:07 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US