- What is the difference between SQL and MySQL?
- What do you mean by DBMS? What are its different types?
- What are the types of joins in SQL? Give an example for each one.
- What is a Primary key?
- What are the different operators available in SQL?
- What is the need for group functions in SQL?
- What is a Relationship and what are they?
Please discuss these questions with your partners and post your answers as a comment on this gist when you are finished.
1.SQL is a language to query databases and MySQL is an an RDBMS. SQL is used to operate manage and access to databases. MySQL allows people to keep the data in a database organized. MySQL uses SQL to query databases. SQL has a standard format since it is a language. MySQL always gets new updates.
DBMS is a computerized data keeping system where users could perform several kinds of operations on that data.
it has four types main types:
Hierarchical database
Network database
Relational database
Object-Oriented database
Inner, Outer, Left, Right
Inner join: return values matches both tables.
Left join: return all records from the left table and the part matches the right table.
The following code will select all customers, and any orders they might have:
Right join: return all records from the right table and the part matches the left table.
The following SQL statement will return all employees, and any orders they might have placed
Full Outer join: return all values that matches with both table
Primary Key: a column or a group of columns in the table that describes and identifies each row in that table.
1-Addition: Adding numbers with “+” sign.
2-Subtraction: Subtracts a number from another with “-” sign.
3-Multiplication: Multiplies two numbers with “*” sign
4-Division: Divides one number by another with “/” sign.
5-Remainder/Modulus:”%” sign returns the remainder from a division.
6- & (Bitwise AND): “&” symbol compares each bit in a value with its corresponding bit in another value.
7- &= (Bitwise AND Assignment)
8- | (Bitwise OR)
9- |= (Bitwise OR Assignment)
10- ^ (Bitwise Exclusive OR)
11- ^= (Bitwise Exclusive OR Assignment)
12- = (Equal to)
13- != (Not Equal to)
14- > (Greater Than)
15- !> (Not Greater Than)
Group functions are mathematical functions to operate on sets of rows to give one result per set.
COUNT MAX MIN AVG SUM
It enables you to group data more clearly and logically, and to summarize data more effectively.
Relationship: relation between tables
Room 8, W/ Amr Nashwaty, Mehmet Fatih Erdem