Re: pg_dumpall --exclude

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Richard Ray wrote:
> I've inherited an application that creates a temp schema and stores 
> a table for each user there.
> The data is temporary and does not need to be backed up.
> I run pg_dumpall each night.
> I can't just delete the tables because users may be working during the 
> backup.
> Any suggestion on how to exclude the temp schema?

You don't say what version of Postgres you are using but 8.2 added this
feature:

     * Allow complex selection of objects to be included or excluded by
       pg_dump (Greg Sabino Mullane) pg_dump now supports multiple -n
       (schema) and -t (table) options, and adds -N and -T options to
       exclude objects.  Also, the arguments of these switches can now be
       wild-card expressions rather than single object names, for example
       -t 'foo*', and a schema can be part of a -t or -T switch, for
       example -t schema1.table1.

-- 
  Bruce Momjian  <bruce@xxxxxxxxxx>        http://momjian.us
  EnterpriseDB                             http://postgres.enterprisedb.com

  + If your life is a hard drive, Christ can be your backup. +

---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?

               http://archives.postgresql.org

[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux