diff options
author | Eric Liang <ekl@databricks.com> | 2016-08-22 15:48:35 -0700 |
---|---|---|
committer | Reynold Xin <rxin@databricks.com> | 2016-08-22 15:48:35 -0700 |
commit | 84770b59f773f132073cd2af4204957fc2d7bf35 (patch) | |
tree | f1f4c739df710ebcc7bfe7a459234102c1cb698b /sql/hive/src/test/resources/sqlgen | |
parent | 929cb8beed9b7014231580cc002853236a5337d6 (diff) | |
download | spark-84770b59f773f132073cd2af4204957fc2d7bf35.tar.gz spark-84770b59f773f132073cd2af4204957fc2d7bf35.tar.bz2 spark-84770b59f773f132073cd2af4204957fc2d7bf35.zip |
[SPARK-17162] Range does not support SQL generation
## What changes were proposed in this pull request?
The range operator previously didn't support SQL generation, which made it not possible to use in views.
## How was this patch tested?
Unit tests.
cc hvanhovell
Author: Eric Liang <ekl@databricks.com>
Closes #14724 from ericl/spark-17162.
Diffstat (limited to 'sql/hive/src/test/resources/sqlgen')
-rw-r--r-- | sql/hive/src/test/resources/sqlgen/range.sql | 4 | ||||
-rw-r--r-- | sql/hive/src/test/resources/sqlgen/range_with_splits.sql | 4 |
2 files changed, 8 insertions, 0 deletions
diff --git a/sql/hive/src/test/resources/sqlgen/range.sql b/sql/hive/src/test/resources/sqlgen/range.sql new file mode 100644 index 0000000000..53c72ea71e --- /dev/null +++ b/sql/hive/src/test/resources/sqlgen/range.sql @@ -0,0 +1,4 @@ +-- This file is automatically generated by LogicalPlanToSQLSuite. +select * from range(100) +-------------------------------------------------------------------------------- +SELECT `gen_attr_0` AS `id` FROM (SELECT `gen_attr_0` FROM (SELECT id AS `gen_attr_0` FROM range(0, 100, 1)) AS gen_subquery_0) AS gen_subquery_1 diff --git a/sql/hive/src/test/resources/sqlgen/range_with_splits.sql b/sql/hive/src/test/resources/sqlgen/range_with_splits.sql new file mode 100644 index 0000000000..83d637d54a --- /dev/null +++ b/sql/hive/src/test/resources/sqlgen/range_with_splits.sql @@ -0,0 +1,4 @@ +-- This file is automatically generated by LogicalPlanToSQLSuite. +select * from range(1, 100, 20, 10) +-------------------------------------------------------------------------------- +SELECT `gen_attr_0` AS `id` FROM (SELECT `gen_attr_0` FROM (SELECT id AS `gen_attr_0` FROM range(1, 100, 20, 10)) AS gen_subquery_0) AS gen_subquery_1 |