local exchange (GATHER, SINGLE, [])
    remote exchange (GATHER, SINGLE, [])
        final aggregation over (i_item_desc, i_item_id, s_store_id, s_store_name)
            local exchange (GATHER, SINGLE, [])
                remote exchange (REPARTITION, HASH, ["i_item_desc", "i_item_id", "s_store_id", "s_store_name"])
                    partial aggregation over (i_item_desc, i_item_id, s_store_id, s_store_name)
                        join (INNER, PARTITIONED):
                            remote exchange (REPARTITION, HASH, ["i_item_sk", "sr_customer_sk"])
                                join (INNER, REPLICATED):
                                    join (INNER, REPLICATED):
                                        join (INNER, PARTITIONED):
                                            remote exchange (REPARTITION, HASH, ["ss_customer_sk", "ss_item_sk", "ss_ticket_number"])
                                                join (INNER, REPLICATED):
                                                    scan store_sales
                                                    local exchange (GATHER, SINGLE, [])
                                                        remote exchange (REPLICATE, BROADCAST, [])
                                                            scan date_dim
                                            local exchange (GATHER, SINGLE, [])
                                                remote exchange (REPARTITION, HASH, ["sr_customer_sk", "sr_item_sk", "sr_ticket_number"])
                                                    join (INNER, REPLICATED):
                                                        scan store_returns
                                                        local exchange (GATHER, SINGLE, [])
                                                            remote exchange (REPLICATE, BROADCAST, [])
                                                                scan date_dim
                                        local exchange (GATHER, SINGLE, [])
                                            remote exchange (REPLICATE, BROADCAST, [])
                                                scan store
                                    local exchange (GATHER, SINGLE, [])
                                        remote exchange (REPLICATE, BROADCAST, [])
                                            scan item
                            local exchange (GATHER, SINGLE, [])
                                remote exchange (REPARTITION, HASH, ["cs_bill_customer_sk", "cs_item_sk"])
                                    join (INNER, REPLICATED):
                                        scan catalog_sales
                                        local exchange (GATHER, SINGLE, [])
                                            remote exchange (REPLICATE, BROADCAST, [])
                                                scan date_dim
