0% found this document useful (0 votes)
1 views1 page

SQL Keywords Cheatsheet

This document is a cheat sheet for SQL keywords, providing brief definitions for each command. Key commands include SELECT for fetching data, WHERE for filtering, and JOIN for combining tables. It also covers data manipulation commands like INSERT, UPDATE, and DELETE, as well as table management commands such as CREATE TABLE and DROP TABLE.

Uploaded by

2019ugec100
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
1 views1 page

SQL Keywords Cheatsheet

This document is a cheat sheet for SQL keywords, providing brief definitions for each command. Key commands include SELECT for fetching data, WHERE for filtering, and JOIN for combining tables. It also covers data manipulation commands like INSERT, UPDATE, and DELETE, as well as table management commands such as CREATE TABLE and DROP TABLE.

Uploaded by

2019ugec100
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

SQL Keywords Cheat Sheet

SELECT: Fetches data from a table.


FROM: Specifies the table to query.
WHERE: Filters rows based on a condition.
AND: Combines multiple conditions (both must be true).
OR: Combines conditions (either can be true).
NOT: Negates a condition.
ORDER BY: Sorts results.
GROUP BY: Groups rows for aggregation.
HAVING: Filters groups (like WHERE but after GROUP BY).
JOIN: Combines rows from two tables.
INNER JOIN: Returns matching rows in both tables.
LEFT JOIN: All rows from left table + matching from right.
RIGHT JOIN: All rows from right table + matching from left.
FULL JOIN: All rows from both tables.
ON: Condition for a JOIN.
LIKE: Pattern match (% = any chars, _ = one char).
IN: Checks if value is in a list.
BETWEEN: Checks if value is within a range.
AS: Gives a temporary alias to a column/table.
DISTINCT: Removes duplicate rows.
LIMIT: Restricts number of rows returned.
INSERT INTO: Adds new rows.
VALUES: Specifies data to insert.
UPDATE: Modifies existing rows.
SET: Specifies columns to update.
DELETE: Removes rows.
CREATE TABLE: Makes a new table.
DROP TABLE: Deletes a table.
ALTER TABLE: Changes a table’s structure.
PRIMARY KEY: Uniquely identifies a row.
FOREIGN KEY: References a key in another table.
NULL: No value.
IS NULL / IS NOT NULL: Checks for null values.

You might also like