时间:2021-07-01 10:21:17 帮助过:21人阅读
SQL> CREATE TABLE Employees ( id INT NOT NULL, age INT NOT NULL, first VARCHAR(255), last VARCHAR(255), PRIMARY KEY ( id ) );
SQL> DROP TABLE table_name;
SQL> INSERT INTO table_name VALUES (column1, column2, ...);
SQL> INSERT INTO Employees VALUES (100, 18, ‘Zara‘, ‘Ali‘);
SQL> SELECT column_name, column_name, ...
FROM table_name
WHERE conditions;
SQL> SELECT first, last, age
FROM Employees
WHERE id = 100;
SQL> UPDATE table_name SET column_name = value, column_name = value, ... WHERE conditions;
WHERE子句可以使用比较操作符例如=,!=,<,>,<=,和>=,以及BETWEEN和LIKE操作符。
SQL> UPDATE Employees SET age=20 WHERE id=100;
SQL> DELETE FROM table_name WHERE conditions;
SQL> DELETE FROM Employees WHERE id=100;
JDBC SQL语法
标签:int 插入 ast style arch 建表 独立 结构化 操作符