FROM table_name
WHERE condition
AND|OR condition
ADD column_name datatype
DROP COLUMN column_name
FROM table_name
FROM table_name AS table_alias
FROM table_name
WHERE column_name
BETWEEN value1 AND value2
ON table_name (column_name)
(
column_name1 data_type,
column_name2 data_type,
.......
)
ON table_name (column_name)
SELECT column_name(s)
FROM table_name
WHERE condition
(Note: Deletes the entire table!!)
or
DELETE FROM table_name
WHERE condition
FROM table_name
GROUP BY column_name1
FROM table_name
GROUP BY column_name1
HAVING SUM(column_name2) condition value
FROM table_name
WHERE column_name
IN (value1,value2,..)
VALUES (value1, value2,....)
or
INSERT INTO table_name
(column_name1, column_name2,...)
VALUES (value1, value2,....)
FROM table_name
WHERE column_name
LIKE pattern
FROM table_name
ORDER BY column_name [ASC|DESC]
FROM table_name
FROM table_name
FROM table_name
(used to create backup copies of tables) SELECT *
INTO new_table_name
FROM original_table_name
or
SELECT column_name(s)
INTO new_table_name
FROM original_table_name
(deletes only the data inside the table) TRUNCATE TABLE table_name
SET column_name=new_value
[, column_name=new_value]
WHERE column_name=some_value
FROM table_name
WHERE condition
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)