Code Monkey home page Code Monkey logo

hs-sql-queries-challenge's Introduction

Let's get ready to query!!!

You should already be connected up to the shared Chinook database for a small music store - like iTunes. Now fork and clone this lab and write out the SQL statements in queries.sql to fulfill each of these queries:

1. Pull a list of all of genres from the database.

2. Pull all of the tracks.

3. How about just the tracks where the composer is AC/DC?

4. Pull all of the tracks greater than 3 minutes long. Hint: You’ll need to figure out how many milliseconds are in a minute.

5. Find the top 5 longest tracks. Hint: Look up how to use ORDER BY and ASC and DESC here

6. Find the top 5 shortest tracks.

Take a look at the customer table.

7. How many customers live in Brazil?

8. How many customers have gmail accounts? Hint: Look up how to use LIKE here

9. What’s the name of the customer who lives at “3 Chatham Street”?

10. Which artist created the album “Ace of Spades”?

11. How many albums does Nirvana have?

Bonus challenge:

  • Use joins to find answers to the last two questions by only writing one query.
    • Watch this video to learn about joining up tables.
    • Or read this blogpost from a Flatiron alum.
    • And take a look at this cheatsheet for an example of a join query.

Cheat Sheets

SQL Cheat Sheet from a Flatiron Alum Select Statements

View Let's get ready to query!!! on Learn.co and start learning to code for free.

hs-sql-queries-challenge's People

Contributors

fislabstest avatar fs-lms-test-bot avatar vanessadean avatar victhevenot avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.