SQL Flashcards
What is the purpose of the group functions in SQL? Give some examples of group functions.
Group functions are necessary to get summary statistics of a data set. COUNT, MAX, MIN, AVG, SUM, and DISTINCT are all group functions.
Tell me the difference between an inner join, left join/right join, and union.
“In a Venn diagram the inner join is when both tables have a match, a left join is when there is a match in the left table and the right table is null, a right join is the opposite of a left join, and a full join is all of the data combined.”
What does UNION do? What is the difference between UNION and UNION ALL?
“UNION removes duplicate records (where all columns in the results are the same), UNION ALL does not.”
What is the difference between SQL and MySQL or SQL Server?
SQL stands for Structured Query Language. It’s a standard language for accessing and manipulating databases. MySQL is a database management system, like SQL Server, Oracle, Informix, Postgres, etc.