#RESOURCES
###SQL:
###Markdown:
###Screenshot:
#LEARNING OBJECTIVES
######SELECT SYNTAX
SELECT column-list FROM table-name
 [WHERE clause]
 [GROUP BY clause]
 [HAVING clause]
 [ORDER BY clause]- WHERE: used when you want to retrieve specific from a table excluding other irrelevant information
 - GROUP BY: used along with the group functions to retrieve data grouped according to one or more columns
 - HAVING: used to filter data based on the group functions
 - ORDER BY: used in a SELECT statement to sort results either in ascending or descending order
 
######OPERATORS
COMPARISON OPERATORS: used to compare the column data with specific values in a condition
LOGICAL OPERATORS: three logical operators AND, OR, and NOT
######COMPARISON KEYWORDS
COMPARISON KEYWORDS: used to enhance the search capabilities of a sql query
######GROUP FUNCTIONS
- COUNT: returns the number of rows in the table
 - MAX: used to get the maximum value from a column
 - MIN: used to get the minimum value from a column
 - AVG: used to get the average value of a numeric column.
 - SUM: used to get the sum of a numeric column
 - DISTINCT: used to select the distinct rows
 
######JOINS JOIN: used to relate information in different tables
There are four types of joins:
- 
- SIMPLE JOIN: returns all rows from multiple tables where the join condition is met
 
 
SELECT column-list 
 FROM table1 JOIN table2 ON (table1.column = table2.column)- 
- LEFT JOIN: returns all rows from the LEFT-hand table specified in the ON condition and only those rows from the other table where the joined fields are equal
 
 
SELECT column-list 
 FROM table1 LEFT JOIN table2 ON (table1.column = table2.column)- 
- RIGHT JOIN: join returns all rows from the RIGHT-hand table specified in the ON condition and only those rows from the other table where the joined fields are equa
 
 
SELECT column-list 
 FROM table1 RIGHT JOIN table2 ON (table1.column = table2.column)- 
- FULL JOIN: join returns all rows from the LEFT-hand table and RIGHT-hand table with nulls in place where the join condition is not met
 
 
SELECT column-list 
 FROM table1 FULL JOIN table2 ON (table1.column = table2.column)######SUBQUERY
SUBQUERY: can be used with SQL SELECT, INSERT, UPDATE, and DELETE as a query within a query
CORRELATED SUBQUERY: both the inner query and the outer query are interdependent








