You are here: SQL Query « MsSQL Server « IT news, forums, messages
SQL Query

Posted by pipe.jack on 01/12/06 23:51

Hello guys,

I'm not an sql expert but I need to pull out some data from SQL
database. I hope you can help me here.
I need to find out how many time a product was ordered. Some product
have the same ProductName but different Option and for me that's a
different product.

Here is the database:

- TABLE OrderDetails -
OrderDetailID
OrderID
ProductName
Options

- TABLE Orders -
OrderID
CustomerID
KeyAccess

The output should look something like this:
NoOrders ProductName ProductOptions KeyAccess
12 Blue car $500 C
7 Blue car $700
C
3 Yellow car $1000 C
1 Yellow car $5000 C
..........................
C = customers


Thanks for any help
Jack

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация