Skip to content

tiy-tpa-ruby/databasics

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Databasics

Fork this repository into your own github profile.

Before finishing the homework assignment:

  • Update answers.txt:
    • For each question include the SQL statement(s) you wrote to generate the answer.
    • For each question include the answer (the sqlite output), if any, to the question asked.

Setup

bash ./setup.sh

Running the CLI

pgcli databasics

To restore your database if you need to reset it:

bash ./setup.sh

Explorer Mode

  1. How many users are there?
  2. What are the titles of the 5 most expensive items?
  3. What's the cheapest item in the Books category?
  4. Who lives at 6439 Zetta Hills, Willmouth, WY?
  5. Correct Virginie Mitchell's address to "New York, NY, 10108".
  6. How much would it cost to buy one of each item in the Tools category?
  7. How many total items did we sell?
  8. How much was spent on Books?
  9. Simulate buying an item by inserting a User for yourself and an Order for yourself.

Adventure Mode

  1. What item has the highest total order quantity?
  2. What user spent the most?
  3. What were the top 3 highest grossing categories?

References

Releases

No releases published

Packages

No packages published

Languages