Dear Expert,
Could you please suggest me for the below query?
I want to vacuum the entire database with the exception of several
tables.
Because there are some tables which are very big in size, so I just want to
exclude them.
Thanks in advance.
Regards,
Dinesh Chandra
|Database
Something like this in a bash script?
#!/bin/bash
echo "select schemaname, tablename from pg_tables where tablename not in
(your list of excluded tables) and schemaname not in
('information_schema', 'pg_catalog')" | psql -t > /tmp/tablist
exec < /tmp/tablist
while read line
do
set -