LMSouq
general-dev Open

Copy table without copying data

MA
Matthew
1 month ago
3 views
Problem Description
CREATE TABLE foo SELECT * FROM bar copies the table `foo` and duplicates it as a new table called `bar`. How can I copy the schema of `foo` to a new table called `bar` **without** copying over the data as well?

AI-Generated Solution

Powered by LMSouq AI · GPT-4.1-mini

✓ Solution Ready
Analyzing problem and generating solution…
Was this solution helpful?
Back to Knowledge Base