Giter VIP home page Giter VIP logo

sql_practice's Introduction

Practice sets for SQL

This is a set of practice questions for SQL. The idea is to give you a set of problems that ask you to use SQL to find certain results. In most cases, the result from the data set will be given. The queries themselves will not be given (as there are generally multiple ways to answer any given query).

For each problem set, I have included the following:

  • Simple CSVs containing the data
  • A simple script, install.sql that can create a database and load the data into a postgres server (this has to be running on your local machine)
  • README.md, which includes the queries and result set you should get for that data set.

There may be additional files (such as a schema) but this is not guaranteed.

Installation

Mac OSX

If you have already install postgres on your system, you only need to run step 3.

  1. Install brew if you haven't installed it already using the following command:
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
  1. Install postgres using brew:
# install postgres
brew install postgresql

# install the start/stop/restart services
brew tap homebrew/services

# create your user, so you can open postgres
createdb 

# start postgre running
brew services start postgresql
  1. Clone this repo and install
git clone https://github.com/kiwidamien/SQL_Practice.git
cd SQL_Practice
sh install_problems.sh

Putting all the commands into one script:

# install homebrew
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

# install postgres
brew install postgresql
createdb 
brew services start postgresql

# get this repo and install it
git clone https://github.com/kiwidamien/SQL_Practice.git
cd SQL_Practice
sh install_problems.sh

Issues?

Please report all issues using Github issues

sql_practice's People

Contributors

kiwidamien avatar

Stargazers

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

Watchers

 avatar  avatar  avatar

sql_practice's Issues

No 06 practice set

As the title state, there is not 6th practice set, it skips from 05 to 07, I don't know if there is supposed to be a 6th practice set, or whether you mistakenly skipped 06, but I figured I would bring it up since I have found this resource helpful for learning PostgreSQL.

Thanks for putting this together kiwidamian!

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.