Statistics are supported for the following only:
- Hive Metastore tables for which
ANALYZE TABLE <tableName> COMPUTE STATISTICS noscanhas been executed
- File-based data source tables for which the statistics are computed directly on the files of data
Broadcast Join can be automatically selected by the Spark Planner based on the Statistics and the spark.sql.autoBroadcastJoinThreshold configuration property.