Skip to content

Instantly share code, notes, and snippets.

@alexleone
Last active January 31, 2020 21:43
Show Gist options
  • Save alexleone/69b6cb0fec6795ad4d651c3eaf0fcee8 to your computer and use it in GitHub Desktop.
Save alexleone/69b6cb0fec6795ad4d651c3eaf0fcee8 to your computer and use it in GitHub Desktop.
Drop all tables from postgres 9.3+
DROP SCHEMA public CASCADE;
CREATE SCHEMA public;
/* Replace 'postgres' with the database name you are working in */
GRANT ALL ON SCHEMA public TO postgres;
GRANT ALL ON SCHEMA public TO public;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment