Script to taking postgres DDL objects with individual file name
I. TAKING TABLE STRUCTRE BACKUP WITH THEIR’S OBJECT FILE NAME : Below scripts helpful to take backup (DDL’s) of procedure, function & table definition with individual file system (object name) based on postgres schema . 1. Windows Script for taking table definition with their object dump file name : Below windows script will be helpful to take the backup of all the table with individual file . D: cd D:\PostgresPlus\9.4AS\bin @echo off SET TableListeFile=D:\InCampusDB\HealthCraft_LC\schemas\wards\Tables\database_list.txt REM Saveing all tables name of database test_db on a temp file: database_list.txt psql -U enterprisedb -d HealthCraft_LC -t -c "SELECT table_name FROM information_schema.tables WHERE table_schema='wards'" -o "%TableListeFile%" REM Loop on liste tables name: FOR /F "tokens=*" %I IN (%TableListeFile%) DO ( REM Dump each table on file pg_dump -U enterprisedb -st wards.%I HealthCraft_LC > "D:\InCampusDB\H...