SQL is a standard language for querying and manipulating databases. It has two main types: DML for data manipulation using SELECT statements, and DDL for data definition using CREATE statements. SQL can be used with many database programs and platforms. Key components of SQL queries include the SELECT, FROM, WHERE, ORDER BY, and GROUP BY clauses. Joins allow data to be retrieved from multiple tables based on matching primary and foreign keys. Aliases provide shorthand names for tables and columns.