title: Can Hive recursively descend into subdirectories without partitions or editing hive-site.xml?
body: <p>I have some web server logs that I'd like to query with Hive. The directory structure, in HDFS, looks like this:</p>
  
  <pre><code>/data/access/web1/2014/09
  /data/access/web1/2014/09/access-20140901.log
  [... etc ...]
  /data/access/web1/2014/10
  /data/access/web1/2014/10/access-20141001.log
  [... etc ...]
  /data/access/web2/2014/09
  /data/access/web2/2014/09/access-20140901.log
  [... etc ...]
  /data/access/web2/2014/10
  /data/access/web2/2014/10/access-20141001.log
  [... etc ...]
  </code></pre>
  
  <p>I'm able to create an external table:</p>
  
  <pre><code>CREATE EXTERNAL TABLE access(
    host STRING,
    identity STRING,
    user STRING,
    time STRING,
    request STRING,
    status STRING,
    size STRING,
    referer STRING,
    agent STRING)
  ROW FORMAT SERDE 'org.apache.hadoop.hive.contrib.serde2.RegexSerDe'
  WITH SERDEPROPERTIES (
    "input.regex" = "([^ ]*) ([^ ]*) ([^ ]*) (-|\\[[^\\]]*\\]) ([^ \"]*|\"[^\"]*\") (-|[0-9]*) (-|[0-9]*)(?: ([^ \"]*|\"[^\"]*\") ([^ \"]*|\"[^\"]*\"))?",
    "output.format.string" = "%1$s %2$s %3$s %4$s %5$s %6$s %7$s %8$s %9$s")
  LOCATION '/data/access/'
  </code></pre>
  
  <p>... though Hive doesn't descend into the subfolders unless I run the following commands before running the Hive query:</p>
  
  <pre><code>set hive.input.dir.recursive=true;
  set hive.mapred.supports.subdirectories=true;
  set hive.supports.subdirectories=true;
  set mapred.input.dir.recursive=true;
  </code></pre>
  
  <p>I've seen other posts set these properties at the table-level (e.g. <a href="https://stackoverflow.com/questions/24708277/issue-creating-hive-external-table-using-tblproperties">Issue creating Hive External table using tblproperties</a>):</p>
  
  <pre><code>TBLPROPERTIES ("hive.input.dir.recursive" = "TRUE", 
      "hive.mapred.supports.subdirectories" = "TRUE",
      "hive.supports.subdirectories" = "TRUE", 
      "mapred.input.dir.recursive" = "TRUE");
  </code></pre>
  
  <p>Unfortunately, this didn't work for me: the table doesn't return any records when I query it. I understand it's possible to set these properties in hive-site.xml, but I'd rather not make any changes that might impact other users if I don't need to.</p>
  
  <p>Q) is there a way to create a table that descends into the subdirectories without using partitions, making site-wide changes, or running those 4 commands every time?</p>