oap-project / gazelle_plugin

Native SQL Engine plugin for Spark SQL with vectorized SIMD optimizations.
Apache License 2.0
256 stars 76 forks source link

Failed to compile TPC-H query based on HDP version Schema #1091

Open kelvin-qin opened 2 years ago

kelvin-qin commented 2 years ago

Describe the bug I created TPC-H 500g data based on the HDP version of the Schema, and when executing 22 queries with Spark NativeSQL, query7, 8, and 9 of them throw obvious compilation errors, causing the query to fail,.

It's log saying: invalid static_cast from type std::string to type int64_t ……

To Reproduce

  1. Create hdp version of TPC-H data(500g)in Hive.see https://github.com/hortonworks/hive-testbench/tree/hdp3/ddl-tpch
  2. Prepare NativeSQL jar(1.3.0 or 1.3.1 & 1.4.0) and Spark3.1.1
  3. Run querys with spark-sql

Expected behavior Finish all queries and Fetched results.

Additional context Use hive flat table. Use TPCH repos:https://github.com/hortonworks/hive-testbench/tree/hdp3/ddl-tpch

zhouyuan commented 2 years ago

This patch should be able fix it, WIP https://github.com/oap-project/gazelle_plugin/pull/1036