You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@drill.apache.org by "benj (JIRA)" <ji...@apache.org> on 2019/05/09 12:47:00 UTC

[jira] [Updated] (DRILL-7247) Use result of DESCRIBE as a SELECT

     [ https://issues.apache.org/jira/browse/DRILL-7247?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

benj updated DRILL-7247:
------------------------
    Description: 
It would be usefull to be able to use the result of a DESCRIBE command like a SELECT.

Examples:
{code:sql}
CREATE TABLE dfs.tmp.`outputTable.csv` AS (DESCRIBE dfs.tmp.`test`);
{code}
{code:sql}
SELECT `COLUMN_NAME` 
FROM (DESCRIBE dfs.tmp.`test`) 
WHERE `DATA_TYPE` LIKE '%INT%';
{code}

  was:
It would be usefull to be able to use the result of a DESCRIBE command like a SELECT.

Examples:
{code:sql}
CREATE TABLE dfs.tmp.`outputTable` AS (DESCRIBE dfs.tmp.`test`);
{code}
{code:sql}
SELECT `COLUMN_NAME` 
FROM (DESCRIBE dfs.tmp.`test`) 
WHERE `DATA_TYPE` LIKE '%INT%';
{code}


> Use result of DESCRIBE as a SELECT
> ----------------------------------
>
>                 Key: DRILL-7247
>                 URL: https://issues.apache.org/jira/browse/DRILL-7247
>             Project: Apache Drill
>          Issue Type: Improvement
>          Components: Storage - Information Schema
>    Affects Versions: 1.16.0
>            Reporter: benj
>            Priority: Major
>
> It would be usefull to be able to use the result of a DESCRIBE command like a SELECT.
> Examples:
> {code:sql}
> CREATE TABLE dfs.tmp.`outputTable.csv` AS (DESCRIBE dfs.tmp.`test`);
> {code}
> {code:sql}
> SELECT `COLUMN_NAME` 
> FROM (DESCRIBE dfs.tmp.`test`) 
> WHERE `DATA_TYPE` LIKE '%INT%';
> {code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)