title: Hive SQL CalcitePlanner: CBO failed due to missing column stats
body: <p>What is the impact of below error in hive and how to avoid it:</p>
  
  <blockquote>
    <p>17/09/14 16:24:25 [main]: ERROR calcite.RelOptHiveTable: No Stats for
    user@table, Columns: xyz column 17/09/14 16:24:25 [main]: ERROR
    parse.CalcitePlanner: CBO failed due to missing column stats (see
    previous errors), skipping CBO</p>
  </blockquote>
  
  <p><strong>SQL query-</strong></p>
  
  <pre><code>create table extractdataset
  as select id,value, sum(rtne) as rtne_sum
  from ( inner query )
  </code></pre>