On Thu, 25 Mar 2021 at 00:05, Tomas Vondra <tomas.von...@enterprisedb.com> wrote: > > here's an updated patch. 0001
The change to the way that CreateStatistics() records dependencies isn't quite right -- recordDependencyOnSingleRelExpr() will not create any dependencies if the expression uses only a whole-row Var. However, pull_varattnos() will include whole-row Vars, and so nattnums_exprs will be non-zero, and CreateStatistics() will not create a whole-table dependency when it should. I suppose that could be fixed up by inspecting the bitmapset returned by pull_varattnos() in more detail, but I think it's probably safer to revert to the previous code, which matched what index_create() did. Regards, Dean