Skip to content

Commit 3e90603

Browse files
authored
Merge pull request Cheatsheet-lang#2 from BuncyShaddai/patch-1
Adding table duplication queries
2 parents d6264f6 + 6627b04 commit 3e90603

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

README.md

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,14 @@ select employee_id, first_name from employee;
163163
```sql
164164
select employee_id, first_name from employee where age > 25;
165165
```
166-
166+
#### Duplicate a Table Schema
167+
```sql
168+
create table table_name like old_table;
169+
````
170+
#### Duplicate a Table
171+
````sql
172+
create table table_name select * from old_table;
173+
````
167174
## Views
168175

169176
#### Create a view

0 commit comments

Comments
 (0)