• Andrew Gierth's avatar
    Optimize nested ConvertRowtypeExpr nodes. · 5613da4c
    Andrew Gierth authored
    A ConvertRowtypeExpr is used to translate a whole-row reference of a
    child to that of a parent. The planner produces nested
    ConvertRowtypeExpr while translating whole-row reference of a leaf
    partition in a multi-level partition hierarchy. Executor then
    translates the whole-row reference from the leaf partition into all
    the intermediate parent's whole-row references before arriving at the
    final whole-row reference. It could instead translate the whole-row
    reference from the leaf partition directly to the top-most parent's
    whole-row reference skipping any intermediate translations.
    
    Ashutosh Bapat, with tests by Kyotaro Horiguchi and some
    editorialization by me. Reviewed by Andres Freund, Pavel Stehule,
    Kyotaro Horiguchi, Dmitry Dolgov, Tom Lane.
    5613da4c
clauses.c 163 KB