class xf::database::gqe::Joiner

#include "gqe_join.hpp"

Overview


Methods

Joiner

Joiner (std::string xclbin)

construct of Joiner .

Parameters:

xclbin xclbin path

join

ErrCode join (
    Table& tab_a,
    std::string filter_a,
    Table& tab_b,
    std::string filter_b,
    std::string join_str,
    Table& tab_c,
    std::string output_str,
    int join_type = INNER_JOIN,
    JoinStrategyBase* strategyimp = nullptr
    )

join function.

Usage:

auto sptr = new gqe::JoinStrategyManualSet(solution, sec_o, sec_l, slice_num, log_part, cpu_aggr);
err_code = bigjoin.join(
    tab_o, "19940101<=o_orderdate && o_orderdate<19950101",
    tab_l, "",
    "o_orderkey = l_orderkey",
    tab_c1, "c1=l_extendedprice, c2=l_discount, c3=o_orderdate, c4=l_orderkey",
    gqe::INNER_JOIN,
    sptr);
delete smanual;

Input filter_a/filter_b like “19940101<=o_orderdate && o_orderdate<19950101”, o_orderdate and o_orderdate must be exsisted colunm names in table a/b when no filter conditions, input “”

Input join conditions like “left_join_key_0=right_join_key_0” when enable dual key join, use comma as seperator, “left_join_key_0=right_join_key_0,left_join_key_1=right_join_key_1”

Output strings are like “output_c0 = tab_a_col/tab_b_col”, when contains several columns, use comma as seperator

Parameters:

tab_a left table
filter_a filter condition of left table
tab_b right table
filter_b filter condition of right table
join_str join condition(s)
tab_c result table
output_str output column mapping
join_type INNER_JOIN(default) | SEMI_JOIN | ANTI_JOIN.
strategyimp pointer to an object of JoinStrategyBase or its derived type.