expected behavior when using wild cards in table name

2016-02-11 Thread Abdel Hakim Deneche
I have the following table tpch100/lineitem that contains 97 parquet files:

tpch100/lineitem/part-m-0.parquet
tpch100/lineitem/part-m-1.parquet
tpch100/lineitem/part-m-2.parquet

...
tpch100/lineitem/part-m-00096.parquet

I can run the following queries:

SELECT COUNT(*) FROM `tpch100/lineit*;
SELECT COUNT(*) FROM `tpch100/lineitem/part-m-0001*';
SELECT COUNT(*) FROM `tpch100/lineitem/*';

The third query will fail if the table has metadata (it has to do with the
.drill.parquet_metadata showing up at the top of the file system results)

My question is: should the 2nd and 3rd queries be allowed, if we are
querying a table folder that doesn't contain any sub folders  ?

-- 

Abdelhakim Deneche

Software Engineer

  


Now Available - Free Hadoop On-Demand Training



Re: expected behavior when using wild cards in table name

2016-02-11 Thread Steven Phillips
I don't understand why they wouldn't be allowed. They seem perfectly valid.

On Thu, Feb 11, 2016 at 9:42 AM, Abdel Hakim Deneche 
wrote:

> I have the following table tpch100/lineitem that contains 97 parquet files:
>
> tpch100/lineitem/part-m-0.parquet
> tpch100/lineitem/part-m-1.parquet
> tpch100/lineitem/part-m-2.parquet
>
> ...
> tpch100/lineitem/part-m-00096.parquet
>
> I can run the following queries:
>
> SELECT COUNT(*) FROM `tpch100/lineit*;
> SELECT COUNT(*) FROM `tpch100/lineitem/part-m-0001*';
> SELECT COUNT(*) FROM `tpch100/lineitem/*';
>
> The third query will fail if the table has metadata (it has to do with the
> .drill.parquet_metadata showing up at the top of the file system results)
>
> My question is: should the 2nd and 3rd queries be allowed, if we are
> querying a table folder that doesn't contain any sub folders  ?
>
> --
>
> Abdelhakim Deneche
>
> Software Engineer
>
>   
>
>
> Now Available - Free Hadoop On-Demand Training
> <
> http://www.mapr.com/training?utm_source=Email_medium=Signature_campaign=Free%20available
> >
>