Skip to content

Latest commit

 

History

History
66 lines (54 loc) · 3.18 KB

File metadata and controls

66 lines (54 loc) · 3.18 KB

img

sql-join-meme

About

While SQL is a powerful language for managing data, it also has many intermediate concepts that can be used to create more complex and nuanced queries. Example of such include Joins, Subqueries , Aggregate Functions Window Functions, Views and Stored Procedures Lets explore the most common of them in this project.

Resources

  1. How to create a new user and assing permission in MySQL
  2. How to use MySQL GRANT statement to assign permissions to users
  3. MySQL constraits
  4. SQL techniques: subqueries
  5. SQL techniques: join
  6. SQL techniqes: multiple joins and the disctint keyword
  7. SQL techniques: join types
  8. SQL techniques: unions and minus
  9. MySQL cheatsheet
  10. Seven Join types
  11. MySQL tutorial
  12. SQL style guide
  13. MySQL 8.0 statement syntax

Extra resources around relational database model design

Design

Normalization

ER modeling

Learning objectives

By the end of this project, you are expected to be able to explain to anyone without the help of Google

  • How to create a new MySQL user
  • How to manage privileges for a user to a database or table
  • What is a PRIMARY KEY
  • What’s a FOREIGN KEY
  • How to use NOT NULL and UNIQUE constraints
  • How to retrieve datas from multiple tables in one request
  • What are subqueries
  • What are JOIN and UNION

How to import a SQL dump

$ echo "CREATE DATABASE hbtn_0d_tvshows;" | mysql -uroot -p
Enter password: 
$ curl "https://s3.amazonaws.com/intranet-projects-files/holbertonschool-higher-level_programming+/274/hbtn_0d_tvshows.sql" -s | mysql -uroot -p hbtn_0d_tvshows
Enter password: 
$ echo "SELECT * FROM tv_genres" | mysql -uroot -p hbtn_0d_tvshows
Enter password: 
id  name
1   Drama
2   Mystery
3   Adventure
4   Fantasy
5   Comedy
6   Crime
7   Suspense
8   Thriller
$

sql-joins-cheat-sheet

Quizes

Quizes