• Michael Paquier's avatar
    Avoid retrieval of CHECK constraints and DEFAULT exprs in data-only dump · 5423853f
    Michael Paquier authored
    Those extra queries are not necessary when doing a data-only dump.  With
    this change, this means that the dependencies between CHECK/DEFAULT and
    the parent table are not tracked anymore for a data-only dump.  However,
    these dependencies are only used for the schema generation and we have
    never guaranteed that a dump can be reloaded if a CHECK constraint uses
    a custom function whose behavior changes when loading the data, like
    when using cross-table references in the CHECK function.
    
    Author: Julien Rouhaud
    Reviewed-by: Daniel Gustafsson, Michael Paquier
    Discussion: https://postgr.es/m/20200712054850.GA92357@nol
    5423853f
pg_dump.c 557 KB