
September 2nd, 2012, 11:45 AM
|
|
Registered User
|
|
Join Date: Sep 2012
Posts: 1
Time spent in forums: 11 m 52 sec
Reputation Power: 0
|
|
|
Why is this SQL code not working?
This is just a very simple code, and if you could help point out why it's not working, it'd be much appreciated.
"
USE Fruit_list
SELECT
a.oranges,
a.pears,
fruitcount = count(*),
apples,
b.banana,
a.dragonfruit
FROM Fruits a
JOIN Fruits b
ON a.banana = b.banana
WHERE dragonfruit between ('20090508') and ('20110508')
AND ActiveFlg = 1
GROUP BY
a.oranges,
a.pears,
apples,
b.banana,
a.dragonfruit
"
Thank you
|