Hi Justin. On 2018/04/04 4:46, Justin Pryzby wrote: > TLDR: even with "faster pruning" patch, pg11dev open()+lseek() every file > backing every table being queried, even for those partitions eventually > "excluded".
That's expected. The faster pruning patch doesn't change the behavior with respect to when the partitions' files are open()'d, which at this point is still *before* the pruning occurs. It just switches the method of pruning to a faster one, whereby instead of pruning each partition one-by-one using constraint exclusion, we only look at the parent's partition descriptor to exclude partitions that don't satisfy the query. Thanks, Amit