Basic Query Question - Mailing list pgsql-novice

From Jude Lucien
Subject Basic Query Question
Date
Msg-id CAPRXF2reaM5Ye4z_A5+7aZ7GowktQC4aeBY5kzu17JEiKzgpwg@mail.gmail.com
Whole thread Raw
Responses Re: Basic Query Question
List pgsql-novice
Sorry for the basic question, I can't seem to figure it out.

I have two tables, booking and bike.  Both have bike_id as primary key.

I am trying to return all bike_id's where bike.model='Kona' AND
booking.booking_date DOES NOT EQUAL 'date';

My query is as follows:

SELECT bike.bike_id FROM bike,booking WHERE bike.model='model' AND
booking.booking_date!='2011-11-20' AND bike.bike_id=booking.bike_id;

Any help appreciated!

Jude



--
"None are more hopelessly enslaved than those who falsely believe they
are free"  -- Johann Wolfgang von Goethe

pgsql-novice by date:

Previous
From: "Jean-Yves F. Barbier"
Date:
Subject: Re: Linux server connection process consumes all memory
Next
From: Ramy Abdel-Azim
Date:
Subject: Re: Basic Query Question