Jump to content

Welcome to Geeks to Go - Register now for FREE

Geeks To Go is a helpful hub, where thousands of volunteer geeks quickly serve friendly answers and support. Check out the forums and get free advice from the experts. Register now to gain access to all of our features, it's FREE and only takes one minute. Once registered and logged in, you will be able to create topics, post replies to existing threads, give reputation to your fellow members, get your own private messenger, post status updates, manage your profile and so much more.

Create Account How it Works
Photo

Urgent, Please help in SQL Queries

SQL

  • Please log in to reply

#1
akriti

akriti

    New Member

  • Member
  • Pip
  • 1 posts

Hi,

 

Please help  me in following queries:

 

Scenario: The database “Cellphones Information” contains details on cell phone sales or transactions.

 

Details stored are: Dim_Manufacturer, Dim_Model, Dim_Customer, Dim_Location and Fact_Transactions. The first four store entries for the respective elements and Fact_Transactions stores all the information about sales of specific cellphones.

 

Tables Structures :Please find attached

 

 

 

Need queries for following:

 

1. What state in the US is buying more 'Samsung' cell phones? Display state and number of cell phone transactions, sort by state.

 

Keep in mind that some manufacturers can be stored in this format: “Name of Manufacturer - Country Code” (e.g. Samsung – Chile, Samsung – Peru, Motorola – Brazil). Also, some of them can be stored in uppercase or lowercase.

 

2. Show the number of transactions for each model per zip code per state. Display manufacturer, model name, state and zip code, even if there are no transactions for a model. Sort by manufacturer name.

 

3. Find out the average price for each model in the top 5 manufacturers in terms of sales quantity, and order by average price;

 

4. List if there is any model that was in the top 5 in terms of quantity, simultaneously in 2008, 2009 and 2010;

 

5. List the names of the customers and the average amount spent in 2009, where the average is higher than 500.00;

 

6. List all the states in which we have customers who have bought cellphones from 2005 till today;

 

7. Show the manufacturers that sold cell phones in 2010 but didn’t in 2009.

 

 

Attached Thumbnails

  • object structure.jpg

  • 0

Advertisements


#2
paws

paws

    WTT Tech Teacher

  • Tech Academy Moderator
  • 636 posts

Hi akriti, and welcome to our forums

 

:welcome:

 

You question looks a little like a school project....

 

If this is not correct then let us know more details of exactly what you are trying to achieve and why?

 

Regards

paws


  • 0






Similar Topics


Also tagged with one or more of these keywords: SQL

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

As Featured On:

Microsoft Yahoo BBC MSN PC Magazine Washington Post HP