Re: SQL
Date: Thu, 31 Jan 2002 18:55:12 GMT
Message-ID: <kqg68.582$sb4.966_at_rwcrnsc51.ops.asp.att.net>
"Girish Mohata" <gmohata_at_yahoo.com> wrote in message
news:42a840c2.0201301808.79b9661f_at_posting.google.com...
> I was wondering you could tell me why my SQL is not working
> correctly.. I need it to query from the database the chemists that
> deliver to a certain area, but then from those only those of the Soul
> Pattinson chain...
Please reformat so this is readable......
>
> Here are my queries with results.:
>
> sql = "SELECT * FROM phoenix.ECShop WHERE DeliveryPostCodes LIKE '%,"
> & CStr(intPCodeID) & ",%' OR DeliveryPostCodes = '" & CStr(intPCodeID)
> & "' OR DeliveryAreas2 LIKE '%," & CStr(intPCodeID) & ",%' OR
> DeliveryAreas2 = '" & CStr(intPCodeID) & "' AND BillNotes LIKE '" &
> strBrand & "' ORDER BY RestaurantName ASC"
> This shows all the chemists in the right area, not just the SP ones.
>
Received on Thu Jan 31 2002 - 19:55:12 CET