Question

The question is:- For the Star Model write an OLAP query that retrieves the quantity, the total income and discount with respect to each city, type of furniture and month.

This is what I have done and want to know is this correct

SELECT Quantity, Income, Discount, City, Type, Month

FROM Sales, Customer, Furniture, Time

WHERE Count(quantity,income,discount)

GROUP BY City, Type, Month; 
Était-ce utile?

La solution

You are misisng to do the JOIN of the tables.

You probably want to JOIN your tables.

Sales, Customer, Furniture and Time

Also try to remove the AND from your queries like

SELECT Quantity, Income, Discount, City, Type , Month
Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top