aboutsummaryrefslogtreecommitdiff
path: root/src/backend/commands/functioncmds.c
diff options
context:
space:
mode:
authorAlvaro Herrera <alvherre@alvh.no-ip.org>2018-07-12 12:09:08 -0400
committerAlvaro Herrera <alvherre@alvh.no-ip.org>2018-07-12 12:18:03 -0400
commit727196ced2423008bb25d7775c4e3b7fca063c8b (patch)
treedaf8fa595aebf21be187450fa3f6316992f4ae4f /src/backend/commands/functioncmds.c
parent510421c45fb41869969a708a8c03c12798a724ec (diff)
downloadpostgresql-727196ced2423008bb25d7775c4e3b7fca063c8b.tar.gz
postgresql-727196ced2423008bb25d7775c4e3b7fca063c8b.zip
Fix FK checks of TRUNCATE involving partitioned tables
When truncating a table that is referenced by foreign keys in partitioned tables, the check to ensure the referencing table are also truncated spuriously failed. This is because it was relying on relhastriggers as a proxy for the table having FKs, and that's wrong for partitioned tables. Fix it to consider such tables separately. There may be a better way ... but this code is pretty inefficient already. Author: Álvaro Herrera <alvherre@alvh.no-ip.org> Reviewed-by: Michael Paquiër <michael@paquier.xyz> Discussion: https://postgr.es/m/20180711000624.zmeizicibxeehhsg@alvherre.pgsql
Diffstat (limited to 'src/backend/commands/functioncmds.c')
0 files changed, 0 insertions, 0 deletions