drill-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kristine Hahn (JIRA)" <j...@apache.org>
Subject [jira] [Created] (DRILL-3399) document how to get the Drill views definition
Date Fri, 26 Jun 2015 18:49:07 GMT
Kristine Hahn created DRILL-3399:

             Summary: document how to get the Drill views definition
                 Key: DRILL-3399
                 URL: https://issues.apache.org/jira/browse/DRILL-3399
             Project: Apache Drill
          Issue Type: Improvement
          Components: Documentation
    Affects Versions: 1.0.0
            Reporter: Kristine Hahn

Document (if not already covered) how to get a view definition, which is sql for which the
drill view is created:
In Drill, a view is just a JSON file, which will live within the workspace where you saved
it. Example:
 create or replace view dfs.workspace.myview as select * from mytable;

 It will create a file called 'myview.view.drill' , which will look
something like this:
 "name" : "testview",
  "sql" : "SELECT *\nFROM `drill/new.json`\nFETCH NEXT 10 ROWS ONLY",
  "fields" : [ {
    "name" : "*",
    "type" : "ANY",
   "isNullable" : true
 } ],
   "workspaceSchemaPath" : [ "dfs", "workspace" ]

This message was sent by Atlassian JIRA

View raw message