| 910 | } |
| 911 | |
| 912 | Result<std::vector<ExecBatch>> HashJoinWithExecPlan( |
| 913 | Random64Bit& rng, bool parallel, const HashJoinNodeOptions& join_options, |
| 914 | const std::shared_ptr<Schema>& output_schema, |
| 915 | const std::vector<std::shared_ptr<Array>>& l, |
| 916 | const std::vector<std::shared_ptr<Array>>& r, int num_batches_l, int num_batches_r) { |
| 917 | // add left source |
| 918 | BatchesWithSchema l_batches = TableToBatches(rng, num_batches_l, l, "l_"); |
| 919 | Declaration left{"source", |
| 920 | SourceNodeOptions{l_batches.schema, l_batches.gen(parallel, |
| 921 | /*slow=*/false)}}; |
| 922 | // add right source |
| 923 | BatchesWithSchema r_batches = TableToBatches(rng, num_batches_r, r, "r_"); |
| 924 | Declaration right{"source", |
| 925 | SourceNodeOptions{r_batches.schema, r_batches.gen(parallel, |
| 926 | /*slow=*/false)}}; |
| 927 | Declaration join{"hashjoin", {std::move(left), std::move(right)}, join_options}; |
| 928 | |
| 929 | ARROW_ASSIGN_OR_RAISE(BatchesWithCommonSchema batches_and_schema, |
| 930 | DeclarationToExecBatches(std::move(join), parallel)); |
| 931 | return batches_and_schema.batches; |
| 932 | } |
| 933 | |
| 934 | TEST(HashJoin, Suffix) { |
| 935 | BatchesWithSchema input_left; |
nothing calls this directly
no test coverage detected