orcale sql select * into
时间: 2023-07-08 18:45:34 浏览: 72
Oracle中的select into
5星 · 资源好评率100%
The syntax for Oracle SQL `SELECT * INTO` statement is different from the standard SQL. In Oracle SQL, you can use the `CREATE TABLE AS SELECT` statement to achieve the same result:
```
CREATE TABLE new_table AS
SELECT * FROM old_table;
```
In this syntax, `new_table` is the name of the table you want to create with the same structure as the `old_table`. The `SELECT *` statement selects all columns from the `old_table`. The `CREATE TABLE AS SELECT` statement creates a new table and inserts the selected data into it.
Note that the `new_table` must not already exist before running this statement. If it does, you will get an error.
阅读全文