can you just try this.
select * from hdfs.json.`/tweets-0.txt`;

On Thu, Oct 23, 2014 at 10:59 AM, Mohit Anchlia <[email protected]>
wrote:

> This is what I see, looks like that file is showing up
>
> sqlline version 1.1.6
> 0: jdbc:drill:zk=local> use hdfs.json;
> +------------+------------+
> |     ok     |  summary   |
> +------------+------------+
> | true       | Default schema changed to 'hdfs.json' |
> +------------+------------+
> 1 row selected (1.112 seconds)
> 0: jdbc:drill:zk=local> show files
> . . . . . . . . . . . > ;
>
> +------------+-------------+------------+------------+------------+------------+-------------+------------+------------------+
> |    name    | isDirectory |   isFile   |   length   |   owner    |
> group    | permissions | accessTime | modificationTime |
>
> +------------+-------------+------------+------------+------------+------------+-------------+------------+------------------+
> | tweets-0.txt | false       | true       | 2097437    | root       |
> supergroup | rw-r--r--   | 2014-10-22 19:26:15.458 | 2014-10-22
> 14:04:26.585 |
> | tweets-1.txt | false       | true       | 1998156    | root       |
> supergroup | rw-r--r--   | 2014-10-22 14:04:26.616 | 2014-10-22
> 14:04:37.123 |
>
> +------------+-------------+------------+------------+------------+------------+-------------+------------+------------------+
> 2 rows selected (0.264 seconds)
> 0: jdbc:drill:zk=local>
>
> On Thu, Oct 23, 2014 at 10:56 AM, Jason Altekruse <
> [email protected]>
> wrote:
>
> > Could you try running 'show files' from the sqllline prompt to see if
> that
> > gives you any results for files Drill is able to find?
> >
> > On Thu, Oct 23, 2014 at 10:43 AM, Mohit Anchlia <[email protected]>
> > wrote:
> >
> > > Could somebody look at this error and advise what might be wrong? It
> > seems
> > > I am doing everything that's documented.
> > > On Wed, Oct 22, 2014 at 2:20 PM, Mohit Anchlia <[email protected]
> >
> > > wrote:
> > >
> > > > I am getting the following error even though that file exists in hdfs
> > > >
> > > > 0: jdbc:drill:zk=local> select * from
> > > > hdfs.`/user/train/xd/tweets/tmp/tweets-0.txt`;
> > > > Oct 22, 2014 5:16:31 PM
> > org.eigenbase.sql.validate.SqlValidatorException
> > > > <init>
> > > > SEVERE: org.eigenbase.sql.validate.SqlValidatorException: Table
> > > > 'hdfs./user/train/xd/tweets/tmp/tweets-0.txt' not found
> > > > Oct 22, 2014 5:16:31 PM org.eigenbase.util.EigenbaseException <init>
> > > > SEVERE: org.eigenbase.util.EigenbaseContextException: From line 1,
> > column
> > > > 15 to line 1, column 18: Table
> > > > 'hdfs./user/train/xd/tweets/tmp/tweets-0.txt' not found
> > > > Query failed: Failure while parsing sql. Table
> > > > 'hdfs./user/train/xd/tweets/tmp/tweets-0.txt' not found
> > > > [7e1d5c73-0521-480e-b74b-a4fa50e3f4a7]
> > > > Error: exception while executing query: Failure while trying to get
> > next
> > > > result batch. (state=,code=0)
> > > >
> > > >
> > > > I created new plugin called hdfs.
> > > >
> > > > {
> > > >   "type": "file",
> > > >   "enabled": true,
> > > >   "connection": "hdfs://10.225.156.201:9000/",
> > > >   "workspaces": {
> > > >     "json": {
> > > >       "location": "/user/train/xd/tweets/tmp",
> > > >       "writable": false,
> > > >       "storageformat": "json"
> > > >     }
> > > >   },
> > > >   "formats": {
> > > >     "json": {
> > > >       "type": "json"
> > > >     }
> > > >   }
> > > > }
> > > >
> > >
> >
>

Reply via email to