incubator-drill-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Varadharajan M <varad...@thoughtworks.com>
Subject Usage of 'store' operation in Logical Queries
Date Sat, 19 Oct 2013 18:06:57 GMT
Hi All,

I've a logical plan, thats intended to read from a json file and write the
output to another file. I was under the impression that the write operation
could be done with the help of 'store' operation. Here is my logical plan:

{
  "head" : {
    "type" : "APACHE_DRILL_LOGICAL",
    "version" : "1",
    "generator" : {
    "type" : "optiq",
    "info" : "na"
    }
  },

  "storage" : {
    "jsonl" : {
      "type" : "json",
      "dfsName" : "file:///"
    },
    "filel" : {
      "type" : "fs",
      "root" : "file:///"
    }
  },

  "query" : [ {
    "op" : "scan",
    "memo" : "initial_scan",
    "ref" : "_MAP",
    "storageengine" : "jsonl",
    "selection" : [ {
      "path" : "/tmp/students.json"
    } ],
    "@id" : 1
  },

  {
    "op" : "store",
    "input" : 1,
    "memo" : "output sink",
    "storageengine": "filel",
    "@id" : 2,
     target: {
        file: "file:///tmp/do.json"
      }
  } ]
}


Now, if i try to run this logical plan with the submit_plan shell script, i
get the output to the console rather than to the specified file (That is,
there is no data written to the file). Am i missing anything here?

- Varadha

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message