@@ -1537,7 +1537,7 @@ ExecCreatePartitionPruneState(PlanState *planstate,
15371537ListCell * lc ;
15381538int i ;
15391539
1540- /* For data reading, executor alwaysomits detached partitions */
1540+ /* For data reading, executor alwaysincludes detached partitions */
15411541if (estate -> es_partition_directory == NULL )
15421542estate -> es_partition_directory =
15431543CreatePartitionDirectory (estate -> es_query_cxt , false);
@@ -1620,8 +1620,8 @@ ExecCreatePartitionPruneState(PlanState *planstate,
16201620 * this by creating new subplan_map and subpart_map arrays that
16211621 * corresponds to the ones in the PruneInfo where the new
16221622 * partition descriptor's OIDs match. Any that don't match can be
1623- * set to -1, as if they were pruned.Both arrays must be in
1624- *numerical OID order.
1623+ * set to -1, as if they were pruned.By construction, both
1624+ *arrays are in partition bounds order.
16251625 */
16261626pprune -> nparts = partdesc -> nparts ;
16271627pprune -> subplan_map = palloc (sizeof (int )* partdesc -> nparts );