diff --git a/src/backend/distributed/commands/utility_hook.c b/src/backend/distributed/commands/utility_hook.c index a554af20a..04ba4d209 100644 --- a/src/backend/distributed/commands/utility_hook.c +++ b/src/backend/distributed/commands/utility_hook.c @@ -666,8 +666,11 @@ ProcessUtilityInternal(PlannedStmt *pstmt, * MarkObjectDistributedLocally since altering already distributed object won't * call MarkObjectDistributedLocally but will hit the check here. */ - ObjectAddress targetObject = GetObjectAddressFromParseTree(parsetree, false); - ErrorIfCircularDependencyExists(&targetObject); + if (ops && ops->address) + { + ObjectAddress targetObject = GetObjectAddressFromParseTree(parsetree, true); + ErrorIfCircularDependencyExists(&targetObject); + } if (ops && ops->postprocess) {