Hi,

I'm running a simple query that joins two tables, where one table is much
larger than the other, with the second table being very small. I believe it
would be optimal to use a broadcast on the second table for the join. All
my tests are being done locally, with very little data in either table.
When I apply the hint to perform the broadcast and check the execution
plan, I see that, whether the hint is present or not, the join is done
using a hash shuffle. Does the hint not enforce the broadcast? Could it be
because I’m running it locally or because the tables contain very few
records?
I'm executing all test from FlinkSQL and sql-client.


EXPLAIN  PLAN FOR
 SELECT /*+ BROADCAST(smalltable) */
    bigtable.eventTimestamp,
    bigtable.field1,
....
    smalltable.technology
FROM bigtable
JOIN smalltable FOR SYSTEM_TIME AS OF EventTimestampLtz
    ON bigtable.cgi = smalltable.cgi;

Reply via email to