Still Getting SQL Syntax Error

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I had posted a question on SQL syntax error, unfortunately Im still getting
the the same error even after correcting it as advised by Mathias Klaey and
John Vinson.
What could be the other problem?, should I re-post exactly what Im trying to
achieve?

Please help.
 
You might try:

SELECT Stock.Item, Sum(Stock.Quantity),
Sum(Sales.[Item Bought])
FROM Stock INNER JOIN Sales ON Stock.Item = Sales.[Item Bought]
GROUP BY Stock.Item

However, if there's a one-to-many relation between Stock and Sales, you are
going to double-count Stock.Quantity, which may not be what you want.
 
Back
Top