From b0c76a801ac3101a5619e36afc0cf46618aa6968 Mon Sep 17 00:00:00 2001 From: Marko Kreen Date: Thu, 12 Jul 2007 20:30:35 +0000 Subject: [PATCH] londiste fkeys: include fkeys for dependents --- python/londiste/setup.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/python/londiste/setup.py b/python/londiste/setup.py index d7fe6897..678fe86c 100644 --- a/python/londiste/setup.py +++ b/python/londiste/setup.py @@ -300,8 +300,8 @@ class SubscriberSetup(CommonSetup): q = "SELECT n.nspname || '.' || t.relname as tbl, c.conname as con,"\ " pg_get_constraintdef(c.oid) as def"\ " FROM pg_constraint c, pg_class t, pg_namespace n"\ - " WHERE c.contype = 'f' and c.conrelid in (%s)"\ - " AND t.oid = c.conrelid AND n.oid = t.relnamespace" % oid_str + " WHERE c.contype = 'f' and (c.conrelid in (%s) or c.confrelid in (%s))"\ + " AND t.oid = c.conrelid AND n.oid = t.relnamespace" % (oid_str, oid_str) dst_curs.execute(q) res = dst_curs.dictfetchall() dst_db.commit() -- 2.39.5