delete all tables from database postgres code example
Example 1: how to remove tables from postgresql
DROP TABLE IF EXISTS tablename;
Example 2: force drop all tables postgres
DROP SCHEMA public CASCADE;
CREATE SCHEMA public;
DROP TABLE IF EXISTS tablename;
DROP SCHEMA public CASCADE;
CREATE SCHEMA public;