First, query statements
Get the first 10 records of data
Oracle
SELECT * from tab where rownum <= 10;
SQL Server:
Select Top Ten * from tab
Mysql:
SELECT * from tab limit 10
SELECT * FROM table name limit m,n; Starting with M, take N bar
Second, update the statement
UPDATE table name SET column name = new value WHERE Column name = value
Update < table name > set < column name > = < value > WHERE condition
Third, delete the statement
Oracle
1. D ROP To Delete a table:
DROP TABLE table_name;
2,Truncate Delete all the data in the table:
Trancate table table_name;
3. D elete to delete a row that satisfies a condition:
Delete from table_name where your_conditions;
Commit
SQL Server:
1. D ROP
DROP table TB--TB indicates the name of the data table delete the entire table (table data and table structure)
2. T runcate
TRUNCATE TABLE TB deletes the entire sheet data without deleting the table structure
3,Delete
Delete Table TB where condition Delete eligible data in table, delete by row
Mysql:
1. D ROP To Delete a table:
DROP TABLE table_name;
2. T runcate Delete all data from the table:
Trancate table table_name;
3. D elete to delete a row that satisfies a condition:
Delete from table_name where your_conditions;
Commit
SQL statement Query Update delete