hive-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From amareshw...@apache.org
Subject svn commit: r1476039 [10/22] - in /hive/branches/HIVE-4115: ./ beeline/ beeline/src/java/org/apache/hive/beeline/ bin/ builtins/ cli/ common/src/java/org/apache/hadoop/hive/conf/ conf/ data/files/ eclipse-templates/ hbase-handler/ hbase-handler/src/jav...
Date Fri, 26 Apr 2013 04:59:58 GMT
Modified: hive/branches/HIVE-4115/ql/src/test/org/apache/hadoop/hive/ql/io/orc/TestFileDump.java
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/org/apache/hadoop/hive/ql/io/orc/TestFileDump.java?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/org/apache/hadoop/hive/ql/io/orc/TestFileDump.java (original)
+++ hive/branches/HIVE-4115/ql/src/test/org/apache/hadoop/hive/ql/io/orc/TestFileDump.java Fri Apr 26 04:59:50 2013
@@ -94,7 +94,7 @@ public class TestFileDump {
       inspector = ObjectInspectorFactory.getReflectionObjectInspector
           (MyRecord.class, ObjectInspectorFactory.ObjectInspectorOptions.JAVA);
     }
-    Writer writer = OrcFile.createWriter(fs, testFilePath, inspector,
+    Writer writer = OrcFile.createWriter(fs, testFilePath, conf, inspector,
         100000, CompressionKind.ZLIB, 10000, 10000);
     Random r1 = new Random(1);
     String[] words = new String[]{"It", "was", "the", "best", "of", "times,",

Modified: hive/branches/HIVE-4115/ql/src/test/org/apache/hadoop/hive/ql/io/orc/TestOrcFile.java
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/org/apache/hadoop/hive/ql/io/orc/TestOrcFile.java?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/org/apache/hadoop/hive/ql/io/orc/TestOrcFile.java (original)
+++ hive/branches/HIVE-4115/ql/src/test/org/apache/hadoop/hive/ql/io/orc/TestOrcFile.java Fri Apr 26 04:59:50 2013
@@ -189,7 +189,7 @@ public class TestOrcFile {
       inspector = ObjectInspectorFactory.getReflectionObjectInspector
           (BigRow.class, ObjectInspectorFactory.ObjectInspectorOptions.JAVA);
     }
-    Writer writer = OrcFile.createWriter(fs, testFilePath, inspector,
+    Writer writer = OrcFile.createWriter(fs, testFilePath, conf, inspector,
         100000, CompressionKind.ZLIB, 10000, 10000);
     writer.addRow(new BigRow(false, (byte) 1, (short) 1024, 65536,
         Long.MAX_VALUE, (float) 1.0, -15.0, bytes(0,1,2,3,4), "hi",
@@ -421,7 +421,7 @@ public class TestOrcFile {
           (InnerStruct.class,
               ObjectInspectorFactory.ObjectInspectorOptions.JAVA);
     }
-    Writer writer = OrcFile.createWriter(fs, testFilePath, inspector,
+    Writer writer = OrcFile.createWriter(fs, testFilePath, conf, inspector,
         1000, CompressionKind.NONE, 100, 1000);
     Random r1 = new Random(1);
     Random r2 = new Random(2);
@@ -504,7 +504,7 @@ public class TestOrcFile {
       inspector = ObjectInspectorFactory.getReflectionObjectInspector
           (BigRow.class, ObjectInspectorFactory.ObjectInspectorOptions.JAVA);
     }
-    Writer writer = OrcFile.createWriter(fs, testFilePath, inspector,
+    Writer writer = OrcFile.createWriter(fs, testFilePath, conf, inspector,
         1000, CompressionKind.NONE, 100, 10000);
     writer.close();
     Reader reader = OrcFile.createReader(fs, testFilePath);
@@ -524,7 +524,7 @@ public class TestOrcFile {
       inspector = ObjectInspectorFactory.getReflectionObjectInspector
           (BigRow.class, ObjectInspectorFactory.ObjectInspectorOptions.JAVA);
     }
-    Writer writer = OrcFile.createWriter(fs, testFilePath, inspector,
+    Writer writer = OrcFile.createWriter(fs, testFilePath, conf, inspector,
         1000, CompressionKind.NONE, 100, 10000);
     writer.addUserMetadata("my.meta", byteBuf(1, 2, 3, 4, 5, 6, 7, -1, -2, 127, -128));
     writer.addUserMetadata("clobber", byteBuf(1,2,3));
@@ -590,7 +590,7 @@ public class TestOrcFile {
       inspector = OrcStruct.createObjectInspector(0, types);
     }
     HiveDecimal maxValue = new HiveDecimal("100000000000000000000");
-    Writer writer = OrcFile.createWriter(fs, testFilePath, inspector,
+    Writer writer = OrcFile.createWriter(fs, testFilePath, conf, inspector,
         1000, CompressionKind.NONE, 100, 10000);
     OrcStruct row = new OrcStruct(3);
     OrcUnion union = new OrcUnion();
@@ -767,7 +767,7 @@ public class TestOrcFile {
           (InnerStruct.class,
               ObjectInspectorFactory.ObjectInspectorOptions.JAVA);
     }
-    Writer writer = OrcFile.createWriter(fs, testFilePath, inspector,
+    Writer writer = OrcFile.createWriter(fs, testFilePath, conf, inspector,
         1000, CompressionKind.SNAPPY, 100, 10000);
     Random rand = new Random(12);
     for(int i=0; i < 10000; ++i) {
@@ -802,7 +802,7 @@ public class TestOrcFile {
           (InnerStruct.class,
               ObjectInspectorFactory.ObjectInspectorOptions.JAVA);
     }
-    Writer writer = OrcFile.createWriter(fs, testFilePath, inspector,
+    Writer writer = OrcFile.createWriter(fs, testFilePath, conf, inspector,
         5000, CompressionKind.SNAPPY, 1000, 0);
     Random rand = new Random(24);
     for(int i=0; i < 10000; ++i) {
@@ -843,7 +843,7 @@ public class TestOrcFile {
       inspector = ObjectInspectorFactory.getReflectionObjectInspector
           (BigRow.class, ObjectInspectorFactory.ObjectInspectorOptions.JAVA);
     }
-    Writer writer = OrcFile.createWriter(fs, testFilePath, inspector,
+    Writer writer = OrcFile.createWriter(fs, testFilePath, conf, inspector,
         200000, CompressionKind.ZLIB, 65536, 1000);
     Random rand = new Random(42);
     final int COUNT=32768;
@@ -936,4 +936,68 @@ public class TestOrcFile {
         (float) doubleValues[i], doubleValues[i], byteValues[i],stringValues[i],
         new MiddleStruct(inner, inner2), list(), map(inner,inner2));
   }
+
+  private static class MyMemoryManager extends MemoryManager {
+    final long totalSpace;
+    double rate;
+    Path path = null;
+    long lastAllocation = 0;
+
+    MyMemoryManager(Configuration conf, long totalSpace, double rate) {
+      super(conf);
+      this.totalSpace = totalSpace;
+      this.rate = rate;
+    }
+
+    @Override
+    void addWriter(Path path, long requestedAllocation,
+                   MemoryManager.Callback callback) {
+      this.path = path;
+      this.lastAllocation = requestedAllocation;
+    }
+
+    @Override
+    synchronized void removeWriter(Path path) {
+      this.path = null;
+      this.lastAllocation = 0;
+    }
+
+    @Override
+    long getTotalMemoryPool() {
+      return totalSpace;
+    }
+
+    @Override
+    double getAllocationScale() {
+      return rate;
+    }
+  }
+
+  @Test
+  public void testMemoryManagement() throws Exception {
+    ObjectInspector inspector;
+    synchronized (TestOrcFile.class) {
+      inspector = ObjectInspectorFactory.getReflectionObjectInspector
+          (InnerStruct.class,
+              ObjectInspectorFactory.ObjectInspectorOptions.JAVA);
+    }
+    MyMemoryManager memory = new MyMemoryManager(conf, 10000, 0.1);
+    Writer writer = new WriterImpl(fs, testFilePath, inspector,
+        50000, CompressionKind.NONE, 100, 0, memory);
+    assertEquals(testFilePath, memory.path);
+    for(int i=0; i < 2500; ++i) {
+      writer.addRow(new InnerStruct(i*300, Integer.toHexString(10*i)));
+    }
+    writer.close();
+    assertEquals(null, memory.path);
+    Reader reader = OrcFile.createReader(fs, testFilePath);
+    int i = 0;
+    for(StripeInformation stripe: reader.getStripes()) {
+      i += 1;
+      assertTrue("stripe " + i + " is too long at " + stripe.getDataLength(),
+          stripe.getDataLength() < 10000);
+    }
+    assertEquals(3, i);
+    assertEquals(2500, reader.getNumberOfRows());
+  }
 }

Modified: hive/branches/HIVE-4115/ql/src/test/org/apache/hadoop/hive/ql/security/TestAuthorizationPreEventListener.java
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/org/apache/hadoop/hive/ql/security/TestAuthorizationPreEventListener.java?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/org/apache/hadoop/hive/ql/security/TestAuthorizationPreEventListener.java (original)
+++ hive/branches/HIVE-4115/ql/src/test/org/apache/hadoop/hive/ql/security/TestAuthorizationPreEventListener.java Fri Apr 26 04:59:50 2013
@@ -169,7 +169,7 @@ public class TestAuthorizationPreEventLi
   }
 
   public void testListener() throws Exception {
-    String dbName = "tmpdb";
+    String dbName = "hive3705";
     String tblName = "tmptbl";
     String renamed = "tmptbl2";
     int listSize = 0;
@@ -199,7 +199,7 @@ public class TestAuthorizationPreEventLi
 
     driver.run("alter table tmptbl add partition (b='2011')");
     listSize++;
-    Partition part = msc.getPartition("tmpdb", "tmptbl", "b=2011");
+    Partition part = msc.getPartition("hive3705", "tmptbl", "b=2011");
 
     Partition ptnFromEvent = (
         (org.apache.hadoop.hive.ql.metadata.Partition)

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_00_unsupported_schema.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_00_unsupported_schema.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_00_unsupported_schema.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_00_unsupported_schema.q Fri Apr 26 04:59:50 2013
@@ -5,7 +5,7 @@ create table exim_department ( dep_id in
 	stored as textfile
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;	
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'nosuchschema://nosuchauthority/ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_01_nonpart_over_loaded.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_01_nonpart_over_loaded.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_01_nonpart_over_loaded.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_01_nonpart_over_loaded.q Fri Apr 26 04:59:50 2013
@@ -5,7 +5,7 @@ create table exim_department ( dep_id in
 	stored as textfile
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;	
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_02_all_part_over_overlap.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_02_all_part_over_overlap.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_02_all_part_over_overlap.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_02_all_part_over_overlap.q Fri Apr 26 04:59:50 2013
@@ -14,7 +14,7 @@ load data local inpath "../data/files/te
 	into table exim_employee partition (emp_country="us", emp_state="tn");	
 load data local inpath "../data/files/test.dat" 
 	into table exim_employee partition (emp_country="us", emp_state="ka");		
-dfs -mkdir ../build/ql/test/data/exports/exim_employee/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_employee/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_employee;
 export table exim_employee to 'ql/test/data/exports/exim_employee';
 drop table exim_employee;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_03_nonpart_noncompat_colschema.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_03_nonpart_noncompat_colschema.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_03_nonpart_noncompat_colschema.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_03_nonpart_noncompat_colschema.q Fri Apr 26 04:59:50 2013
@@ -5,7 +5,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;	
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_04_nonpart_noncompat_colnumber.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_04_nonpart_noncompat_colnumber.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_04_nonpart_noncompat_colnumber.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_04_nonpart_noncompat_colnumber.q Fri Apr 26 04:59:50 2013
@@ -5,7 +5,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;	
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_05_nonpart_noncompat_coltype.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_05_nonpart_noncompat_coltype.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_05_nonpart_noncompat_coltype.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_05_nonpart_noncompat_coltype.q Fri Apr 26 04:59:50 2013
@@ -5,7 +5,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;	
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_06_nonpart_noncompat_storage.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_06_nonpart_noncompat_storage.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_06_nonpart_noncompat_storage.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_06_nonpart_noncompat_storage.q Fri Apr 26 04:59:50 2013
@@ -5,7 +5,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;	
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_07_nonpart_noncompat_ifof.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_07_nonpart_noncompat_ifof.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_07_nonpart_noncompat_ifof.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_07_nonpart_noncompat_ifof.q Fri Apr 26 04:59:50 2013
@@ -5,7 +5,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;	
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_08_nonpart_noncompat_serde.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_08_nonpart_noncompat_serde.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_08_nonpart_noncompat_serde.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_08_nonpart_noncompat_serde.q Fri Apr 26 04:59:50 2013
@@ -5,7 +5,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;	
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_09_nonpart_noncompat_serdeparam.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_09_nonpart_noncompat_serdeparam.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_09_nonpart_noncompat_serdeparam.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_09_nonpart_noncompat_serdeparam.q Fri Apr 26 04:59:50 2013
@@ -5,7 +5,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;	
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_10_nonpart_noncompat_bucketing.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_10_nonpart_noncompat_bucketing.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_10_nonpart_noncompat_bucketing.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_10_nonpart_noncompat_bucketing.q Fri Apr 26 04:59:50 2013
@@ -5,7 +5,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;	
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_11_nonpart_noncompat_sorting.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_11_nonpart_noncompat_sorting.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_11_nonpart_noncompat_sorting.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_11_nonpart_noncompat_sorting.q Fri Apr 26 04:59:50 2013
@@ -6,7 +6,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;	
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_13_nonnative_import.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_13_nonnative_import.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_13_nonnative_import.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_13_nonnative_import.q Fri Apr 26 04:59:50 2013
@@ -5,7 +5,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;		
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_14_nonpart_part.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_14_nonpart_part.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_14_nonpart_part.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_14_nonpart_part.q Fri Apr 26 04:59:50 2013
@@ -5,7 +5,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;		
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_15_part_nonpart.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_15_part_nonpart.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_15_part_nonpart.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_15_part_nonpart.q Fri Apr 26 04:59:50 2013
@@ -6,7 +6,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department partition (dep_org="hr");		
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_16_part_noncompat_schema.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_16_part_noncompat_schema.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_16_part_noncompat_schema.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_16_part_noncompat_schema.q Fri Apr 26 04:59:50 2013
@@ -6,7 +6,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department partition (dep_org="hr");		
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_17_part_spec_underspec.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_17_part_spec_underspec.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_17_part_spec_underspec.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_17_part_spec_underspec.q Fri Apr 26 04:59:50 2013
@@ -14,7 +14,7 @@ load data local inpath "../data/files/te
 	into table exim_employee partition (emp_country="us", emp_state="tn");	
 load data local inpath "../data/files/test.dat" 
 	into table exim_employee partition (emp_country="us", emp_state="ka");		
-dfs -mkdir ../build/ql/test/data/exports/exim_employee/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_employee/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_employee;
 export table exim_employee to 'ql/test/data/exports/exim_employee';
 drop table exim_employee;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_18_part_spec_missing.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_18_part_spec_missing.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_18_part_spec_missing.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_18_part_spec_missing.q Fri Apr 26 04:59:50 2013
@@ -14,7 +14,7 @@ load data local inpath "../data/files/te
 	into table exim_employee partition (emp_country="us", emp_state="tn");	
 load data local inpath "../data/files/test.dat" 
 	into table exim_employee partition (emp_country="us", emp_state="ka");		
-dfs -mkdir ../build/ql/test/data/exports/exim_employee/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_employee/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_employee;
 export table exim_employee to 'ql/test/data/exports/exim_employee';
 drop table exim_employee;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_19_external_over_existing.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_19_external_over_existing.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_19_external_over_existing.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_19_external_over_existing.q Fri Apr 26 04:59:50 2013
@@ -5,7 +5,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;		
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_20_managed_location_over_existing.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_20_managed_location_over_existing.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_20_managed_location_over_existing.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_20_managed_location_over_existing.q Fri Apr 26 04:59:50 2013
@@ -5,7 +5,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;		
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;
@@ -13,7 +13,7 @@ drop table exim_department;
 create database importer;
 use importer;
 
-dfs -mkdir ../build/ql/test/data/tablestore/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/tablestore/exim_department/temp;
 dfs -rmr ../build/ql/test/data/tablestore/exim_department;
 
 create table exim_department ( dep_id int comment "department id") 	

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_21_part_managed_external.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_21_part_managed_external.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_21_part_managed_external.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_21_part_managed_external.q Fri Apr 26 04:59:50 2013
@@ -14,7 +14,7 @@ load data local inpath "../data/files/te
 	into table exim_employee partition (emp_country="us", emp_state="tn");	
 load data local inpath "../data/files/test.dat" 
 	into table exim_employee partition (emp_country="us", emp_state="ka");		
-dfs -mkdir ../build/ql/test/data/exports/exim_employee/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_employee/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_employee;
 export table exim_employee to 'ql/test/data/exports/exim_employee';
 drop table exim_employee;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_22_export_authfail.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_22_export_authfail.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_22_export_authfail.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_22_export_authfail.q Fri Apr 26 04:59:50 2013
@@ -5,7 +5,7 @@ create table exim_department ( dep_id in
 
 set hive.security.authorization.enabled=true;
 
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_23_import_exist_authfail.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_23_import_exist_authfail.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_23_import_exist_authfail.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_23_import_exist_authfail.q Fri Apr 26 04:59:50 2013
@@ -3,7 +3,7 @@ set hive.test.mode.prefix=;
 
 create table exim_department ( dep_id int) stored as textfile;
 load data local inpath "../data/files/test.dat" into table exim_department;
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_24_import_part_authfail.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_24_import_part_authfail.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_24_import_part_authfail.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_24_import_part_authfail.q Fri Apr 26 04:59:50 2013
@@ -9,7 +9,7 @@ create table exim_employee ( emp_id int 
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" 
 	into table exim_employee partition (emp_country="in", emp_state="tn");		
-dfs -mkdir ../build/ql/test/data/exports/exim_employee/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_employee/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_employee;
 export table exim_employee to 'ql/test/data/exports/exim_employee';
 drop table exim_employee;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_25_import_nonexist_authfail.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_25_import_nonexist_authfail.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_25_import_nonexist_authfail.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientnegative/exim_25_import_nonexist_authfail.q Fri Apr 26 04:59:50 2013
@@ -4,7 +4,7 @@ set hive.test.mode.nosamplelist=exim_dep
 
 create table exim_department ( dep_id int) stored as textfile;
 load data local inpath "../data/files/test.dat" into table exim_department;
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/allcolref_in_udf.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/allcolref_in_udf.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/allcolref_in_udf.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/allcolref_in_udf.q Fri Apr 26 04:59:50 2013
@@ -14,3 +14,8 @@ select stack(2, *) as (e1,e2,e3) from (
 select stack(2, *) as (e1,e2,e3) from (
   select concat(*), concat(a.*), concat(b.*), concat(a.*, b.key), concat(a.key, b.*)
   from src a join src b on a.key+1=b.key where a.key < 100) x limit 10;
+
+-- HIVE-4181 TOK_FUNCTIONSTAR for UDTF
+create table allcolref as select array(key, value) from src;
+explain select explode(*) as x from allcolref limit 10;
+select explode(*) as x from allcolref limit 10;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_1.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_1.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_1.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_1.q Fri Apr 26 04:59:50 2013
@@ -1,6 +1,7 @@
 -- small 1 part, 2 bucket & big 2 part, 4 bucket
 
-CREATE TABLE bucket_small (key string, value string) partitioned by (ds string) CLUSTERED BY (key) SORTED BY (key) INTO 2 BUCKETS STORED AS TEXTFILE;
+CREATE TABLE bucket_small (key string, value string) partitioned by (ds string) 
+CLUSTERED BY (key) SORTED BY (key) INTO 2 BUCKETS STORED AS TEXTFILE;
 load data local inpath '../data/files/smallsrcsortbucket1outof4.txt' INTO TABLE bucket_small partition(ds='2008-04-08');
 load data local inpath '../data/files/smallsrcsortbucket2outof4.txt' INTO TABLE bucket_small partition(ds='2008-04-08');
 
@@ -20,6 +21,7 @@ set hive.auto.convert.sortmerge.join=tru
 set hive.optimize.bucketmapjoin = true;
 set hive.optimize.bucketmapjoin.sortedmerge = true;
 
+set hive.auto.convert.sortmerge.join.to.mapjoin=false;
 set hive.auto.convert.sortmerge.join.bigtable.selection.policy = org.apache.hadoop.hive.ql.optimizer.TableSizeBasedBigTableSelectorForAutoSMJ;
 
 -- Since size is being used to find the big table, the order of the tables in the join does not matter
@@ -28,3 +30,7 @@ select count(*) FROM bucket_small a JOIN
 
 explain extended select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
 select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
+
+set hive.auto.convert.sortmerge.join.to.mapjoin=true;
+explain extended select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
+select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_10.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_10.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_10.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_10.q Fri Apr 26 04:59:50 2013
@@ -17,7 +17,7 @@ set hive.optimize.bucketmapjoin.sortedme
 set hive.input.format = org.apache.hadoop.hive.ql.io.BucketizedHiveInputFormat;
 
 set hive.auto.convert.sortmerge.join=true;
-
+set hive.auto.convert.sortmerge.join.to.mapjoin=false;
 -- One of the subqueries contains a union, so it should not be converted to a sort-merge join.
 explain
 select count(*) from 

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_2.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_2.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_2.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_2.q Fri Apr 26 04:59:50 2013
@@ -16,9 +16,17 @@ set hive.auto.convert.join=true;
 set hive.auto.convert.sortmerge.join=true;
 set hive.optimize.bucketmapjoin = true;
 set hive.optimize.bucketmapjoin.sortedmerge = true;
-
+set hive.auto.convert.sortmerge.join.to.mapjoin=false;
 set hive.auto.convert.sortmerge.join.bigtable.selection.policy = org.apache.hadoop.hive.ql.optimizer.LeftmostBigTableSelectorForAutoSMJ;
 
 -- Since the leftmost table is assumed as the big table, arrange the tables in the join accordingly
 explain extended select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
 select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
+
+set hive.auto.convert.sortmerge.join.to.mapjoin=true;
+set hive.mapjoin.localtask.max.memory.usage = 0.0001;
+set hive.mapjoin.check.memory.rows = 2;
+
+-- The mapjoin should fail resulting in the sort-merge join
+explain extended select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
+select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_3.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_3.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_3.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_3.q Fri Apr 26 04:59:50 2013
@@ -16,7 +16,7 @@ set hive.auto.convert.join=true;
 set hive.auto.convert.sortmerge.join=true;
 set hive.optimize.bucketmapjoin = true;
 set hive.optimize.bucketmapjoin.sortedmerge = true;
-
+set hive.auto.convert.sortmerge.join.to.mapjoin=false;
 set hive.auto.convert.sortmerge.join.bigtable.selection.policy = org.apache.hadoop.hive.ql.optimizer.TableSizeBasedBigTableSelectorForAutoSMJ;
 
 -- Since size is being used to find the big table, the order of the tables in the join does not matter
@@ -25,3 +25,7 @@ select count(*) FROM bucket_small a JOIN
 
 explain extended select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
 select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
+
+set hive.auto.convert.sortmerge.join.to.mapjoin=true;
+explain extended select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
+select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_4.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_4.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_4.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_4.q Fri Apr 26 04:59:50 2013
@@ -18,7 +18,7 @@ set hive.auto.convert.join=true;
 set hive.auto.convert.sortmerge.join=true;
 set hive.optimize.bucketmapjoin = true;
 set hive.optimize.bucketmapjoin.sortedmerge = true;
-
+set hive.auto.convert.sortmerge.join.to.mapjoin=false;
 set hive.auto.convert.sortmerge.join.bigtable.selection.policy = org.apache.hadoop.hive.ql.optimizer.AvgPartitionSizeBasedBigTableSelectorForAutoSMJ;
 
 -- Since size is being used to find the big table, the order of the tables in the join does not matter
@@ -27,3 +27,7 @@ select count(*) FROM bucket_small a JOIN
 
 explain extended select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
 select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
+
+set hive.auto.convert.sortmerge.join.to.mapjoin=true;
+explain extended select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
+select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_5.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_5.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_5.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_5.q Fri Apr 26 04:59:50 2013
@@ -12,7 +12,7 @@ load data local inpath '../data/files/sr
 set hive.auto.convert.sortmerge.join=true;
 set hive.optimize.bucketmapjoin = true;
 set hive.optimize.bucketmapjoin.sortedmerge = true;
-
+set hive.auto.convert.sortmerge.join.to.mapjoin=false;
 set hive.auto.convert.sortmerge.join.bigtable.selection.policy = org.apache.hadoop.hive.ql.optimizer.AvgPartitionSizeBasedBigTableSelectorForAutoSMJ;
 
 -- Since size is being used to find the big table, the order of the tables in the join does not matter
@@ -21,3 +21,8 @@ select count(*) FROM bucket_small a JOIN
 
 explain extended select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
 select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
+
+set hive.auto.convert.sortmerge.join.to.mapjoin=true;
+set hive.auto.convert.join=true;
+explain extended select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
+select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_6.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_6.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_6.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_6.q Fri Apr 26 04:59:50 2013
@@ -18,6 +18,24 @@ set hive.optimize.bucketmapjoin.sortedme
 set hive.auto.convert.join=true;
 set hive.auto.convert.join.noconditionaltask=true;
 set hive.auto.convert.join.noconditionaltask.size=200;
+set hive.auto.convert.sortmerge.join.to.mapjoin=false;
+-- A SMB join is being followed by a regular join on a non-bucketed table on a different key
+explain select count(*) FROM tbl1 a JOIN tbl2 b ON a.key = b.key join src c on c.value = a.value;
+select count(*) FROM tbl1 a JOIN tbl2 b ON a.key = b.key join src c on c.value = a.value;
+
+-- A SMB join is being followed by a regular join on a non-bucketed table on the same key
+explain select count(*) FROM tbl1 a JOIN tbl2 b ON a.key = b.key join src c on c.key = a.key;
+select count(*) FROM tbl1 a JOIN tbl2 b ON a.key = b.key join src c on c.key = a.key;
+
+-- A SMB join is being followed by a regular join on a bucketed table on the same key
+explain select count(*) FROM tbl1 a JOIN tbl2 b ON a.key = b.key join tbl3 c on c.key = a.key;
+select count(*) FROM tbl1 a JOIN tbl2 b ON a.key = b.key join tbl3 c on c.key = a.key;
+
+-- A SMB join is being followed by a regular join on a bucketed table on a different key
+explain select count(*) FROM tbl1 a JOIN tbl2 b ON a.key = b.key join tbl4 c on c.value = a.value;
+select count(*) FROM tbl1 a JOIN tbl2 b ON a.key = b.key join tbl4 c on c.value = a.value;
+
+set hive.auto.convert.sortmerge.join.to.mapjoin=true;
 
 -- A SMB join is being followed by a regular join on a non-bucketed table on a different key
 explain select count(*) FROM tbl1 a JOIN tbl2 b ON a.key = b.key join src c on c.value = a.value;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_7.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_7.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_7.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_7.q Fri Apr 26 04:59:50 2013
@@ -21,7 +21,7 @@ set hive.auto.convert.join=true;
 set hive.auto.convert.sortmerge.join=true;
 set hive.optimize.bucketmapjoin = true;
 set hive.optimize.bucketmapjoin.sortedmerge = true;
-
+set hive.auto.convert.sortmerge.join.to.mapjoin=false;
 set hive.auto.convert.sortmerge.join.bigtable.selection.policy = org.apache.hadoop.hive.ql.optimizer.AvgPartitionSizeBasedBigTableSelectorForAutoSMJ;
 
 -- Since size is being used to find the big table, the order of the tables in the join does not matter
@@ -30,3 +30,7 @@ select count(*) FROM bucket_small a JOIN
 
 explain extended select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
 select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
+
+set hive.auto.convert.sortmerge.join.to.mapjoin=true;
+explain extended select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
+select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_8.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_8.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_8.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_8.q Fri Apr 26 04:59:50 2013
@@ -21,7 +21,7 @@ set hive.auto.convert.join=true;
 set hive.auto.convert.sortmerge.join=true;
 set hive.optimize.bucketmapjoin = true;
 set hive.optimize.bucketmapjoin.sortedmerge = true;
-
+set hive.auto.convert.sortmerge.join.to.mapjoin=false;
 set hive.auto.convert.sortmerge.join.bigtable.selection.policy = org.apache.hadoop.hive.ql.optimizer.TableSizeBasedBigTableSelectorForAutoSMJ;
 
 -- Since size is being used to find the big table, the order of the tables in the join does not matter
@@ -30,3 +30,11 @@ select count(*) FROM bucket_small a JOIN
 
 explain extended select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
 select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
+
+set hive.auto.convert.sortmerge.join.to.mapjoin=true;
+set hive.mapjoin.localtask.max.memory.usage = 0.0001;
+set hive.mapjoin.check.memory.rows = 2;
+
+-- The mapjoin should fail resulting in the sort-merge join
+explain extended select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;
+select count(*) FROM bucket_big a JOIN bucket_small b ON a.key = b.key;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_9.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_9.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_9.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/auto_sortmerge_join_9.q Fri Apr 26 04:59:50 2013
@@ -15,7 +15,7 @@ set hive.auto.convert.join=true;
 set hive.optimize.bucketmapjoin = true;
 set hive.optimize.bucketmapjoin.sortedmerge = true;
 set hive.auto.convert.sortmerge.join=true;
-
+set hive.auto.convert.sortmerge.join.to.mapjoin=false;
 -- The join is being performed as part of sub-query. It should be converted to a sort-merge join
 explain
 select count(*) from (
@@ -281,3 +281,256 @@ select count(*) from (
   ) subq2
 join tbl2 b
 on subq2.key = b.key) a;
+
+set hive.auto.convert.sortmerge.join.to.mapjoin=true;
+
+-- The join is being performed as part of sub-query. It should be converted to a sort-merge join
+explain
+select count(*) from (
+  select a.key as key, a.value as val1, b.value as val2 from tbl1 a join tbl2 b on a.key = b.key
+) subq1;
+
+select count(*) from (
+  select a.key as key, a.value as val1, b.value as val2 from tbl1 a join tbl2 b on a.key = b.key
+) subq1;
+
+-- The join is being performed as part of sub-query. It should be converted to a sort-merge join
+-- Add a order by at the end to make the results deterministic.
+explain
+select key, count(*) from 
+(
+  select a.key as key, a.value as val1, b.value as val2 from tbl1 a join tbl2 b on a.key = b.key
+) subq1
+group by key
+order by key;
+
+select key, count(*) from 
+(
+  select a.key as key, a.value as val1, b.value as val2 from tbl1 a join tbl2 b on a.key = b.key
+) subq1
+group by key
+order by key;
+
+-- The join is being performed as part of more than one sub-query. It should be converted to a sort-merge join
+explain
+select count(*) from
+(
+  select key, count(*) from 
+  (
+    select a.key as key, a.value as val1, b.value as val2 from tbl1 a join tbl2 b on a.key = b.key
+  ) subq1
+  group by key
+) subq2;
+
+select count(*) from
+(
+  select key, count(*) from 
+  (
+    select a.key as key, a.value as val1, b.value as val2 from tbl1 a join tbl2 b on a.key = b.key
+  ) subq1
+  group by key
+) subq2;
+
+-- A join is being performed across different sub-queries, where a join is being performed in each of them.
+-- Each sub-query should be converted to a sort-merge join.
+explain
+select src1.key, src1.cnt1, src2.cnt1 from
+(
+  select key, count(*) as cnt1 from 
+  (
+    select a.key as key, a.value as val1, b.value as val2 from tbl1 a join tbl2 b on a.key = b.key
+  ) subq1 group by key
+) src1
+join
+(
+  select key, count(*) as cnt1 from 
+  (
+    select a.key as key, a.value as val1, b.value as val2 from tbl1 a join tbl2 b on a.key = b.key
+  ) subq2 group by key
+) src2
+on src1.key = src2.key
+order by src1.key, src1.cnt1, src2.cnt1;
+
+select src1.key, src1.cnt1, src2.cnt1 from
+(
+  select key, count(*) as cnt1 from 
+  (
+    select a.key as key, a.value as val1, b.value as val2 from tbl1 a join tbl2 b on a.key = b.key
+  ) subq1 group by key
+) src1
+join
+(
+  select key, count(*) as cnt1 from 
+  (
+    select a.key as key, a.value as val1, b.value as val2 from tbl1 a join tbl2 b on a.key = b.key
+  ) subq2 group by key
+) src2
+on src1.key = src2.key
+order by src1.key, src1.cnt1, src2.cnt1;
+
+-- The subquery itself is being joined. Since the sub-query only contains selects and filters, it should 
+-- be converted to a sort-merge join.
+explain
+select count(*) from 
+  (select a.key as key, a.value as value from tbl1 a where key < 6) subq1 
+    join
+  (select a.key as key, a.value as value from tbl2 a where key < 6) subq2
+  on subq1.key = subq2.key;
+
+select count(*) from 
+  (select a.key as key, a.value as value from tbl1 a where key < 6) subq1 
+    join
+  (select a.key as key, a.value as value from tbl2 a where key < 6) subq2
+  on subq1.key = subq2.key;
+
+-- The subquery itself is being joined. Since the sub-query only contains selects and filters, it should 
+-- be converted to a sort-merge join, although there is more than one level of sub-query
+explain
+select count(*) from 
+  (
+  select * from
+    (
+      select a.key as key, a.value as value from tbl1 a where key < 8
+    ) subq1 
+  where key < 6
+  ) subq2
+  join tbl2 b
+  on subq2.key = b.key;
+
+select count(*) from 
+  (
+  select * from
+    (
+      select a.key as key, a.value as value from tbl1 a where key < 8
+    ) subq1 
+  where key < 6
+  ) subq2
+  join tbl2 b
+  on subq2.key = b.key;
+
+-- Both the tables are nested sub-queries i.e more then 1 level of sub-query.
+-- The join should be converted to a sort-merge join
+explain
+select count(*) from 
+  (
+  select * from
+    (
+      select a.key as key, a.value as value from tbl1 a where key < 8
+    ) subq1 
+  where key < 6
+  ) subq2
+  join
+  (
+  select * from
+    (
+      select a.key as key, a.value as value from tbl1 a where key < 8
+    ) subq3 
+  where key < 6
+  ) subq4
+  on subq2.key = subq4.key;
+
+select count(*) from 
+  (
+  select * from
+    (
+      select a.key as key, a.value as value from tbl1 a where key < 8
+    ) subq1 
+  where key < 6
+  ) subq2
+  join
+  (
+  select * from
+    (
+      select a.key as key, a.value as value from tbl1 a where key < 8
+    ) subq3 
+  where key < 6
+  ) subq4
+  on subq2.key = subq4.key;
+
+-- The subquery itself is being joined. Since the sub-query only contains selects and filters and the join key
+-- is not getting modified, it should be converted to a sort-merge join. Note that the sub-query modifies one 
+-- item, but that is not part of the join key.
+explain
+select count(*) from 
+  (select a.key as key, concat(a.value, a.value) as value from tbl1 a where key < 8) subq1 
+    join
+  (select a.key as key, concat(a.value, a.value) as value from tbl2 a where key < 8) subq2
+  on subq1.key = subq2.key;
+
+select count(*) from 
+  (select a.key as key, concat(a.value, a.value) as value from tbl1 a where key < 8) subq1 
+    join
+  (select a.key as key, concat(a.value, a.value) as value from tbl2 a where key < 8) subq2
+  on subq1.key = subq2.key;
+
+-- The left table is a sub-query and the right table is not.
+-- It should be converted to a sort-merge join.
+explain
+select count(*) from 
+  (select a.key as key, a.value as value from tbl1 a where key < 6) subq1 
+    join tbl2 a on subq1.key = a.key;
+
+select count(*) from 
+  (select a.key as key, a.value as value from tbl1 a where key < 6) subq1 
+    join tbl2 a on subq1.key = a.key;
+
+-- The right table is a sub-query and the left table is not.
+-- It should be converted to a sort-merge join.
+explain
+select count(*) from tbl1 a
+  join
+  (select a.key as key, a.value as value from tbl2 a where key < 6) subq1 
+  on a.key = subq1.key;
+
+select count(*) from tbl1 a
+  join
+  (select a.key as key, a.value as value from tbl2 a where key < 6) subq1 
+  on a.key = subq1.key;
+
+-- There are more than 2 inputs to the join, all of them being sub-queries. 
+-- It should be converted to to a sort-merge join
+explain
+select count(*) from 
+  (select a.key as key, a.value as value from tbl1 a where key < 6) subq1 
+    join
+  (select a.key as key, a.value as value from tbl2 a where key < 6) subq2
+  on (subq1.key = subq2.key)
+    join
+  (select a.key as key, a.value as value from tbl2 a where key < 6) subq3
+  on (subq1.key = subq3.key);
+
+select count(*) from 
+  (select a.key as key, a.value as value from tbl1 a where key < 6) subq1 
+    join
+  (select a.key as key, a.value as value from tbl2 a where key < 6) subq2
+  on subq1.key = subq2.key
+    join
+  (select a.key as key, a.value as value from tbl2 a where key < 6) subq3
+  on (subq1.key = subq3.key);
+
+-- The join is being performed on a nested sub-query, and an aggregation is performed after that.
+-- The join should be converted to a sort-merge join
+explain
+select count(*) from (
+  select subq2.key as key, subq2.value as value1, b.value as value2 from
+  (
+    select * from
+    (
+      select a.key as key, a.value as value from tbl1 a where key < 8
+    ) subq1
+    where key < 6
+  ) subq2
+join tbl2 b
+on subq2.key = b.key) a;
+
+select count(*) from (
+  select subq2.key as key, subq2.value as value1, b.value as value2 from
+  (
+    select * from
+    (
+      select a.key as key, a.value as value from tbl1 a where key < 8
+    ) subq1
+    where key < 6
+  ) subq2
+join tbl2 b
+on subq2.key = b.key) a;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_1.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_1.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_1.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_1.q Fri Apr 26 04:59:50 2013
@@ -6,6 +6,8 @@ set hive.exec.reducers.max = 1;
 set hive.merge.mapfiles=false;
 set hive.merge.mapredfiles=false; 
 
+set hive.auto.convert.sortmerge.join.to.mapjoin=true;
+
 -- Create two bucketed and sorted tables
 CREATE TABLE test_table1 (key INT, value STRING) PARTITIONED BY (ds STRING)
 CLUSTERED BY (key) SORTED BY (key) INTO 2 BUCKETS;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_2.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_2.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_2.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_2.q Fri Apr 26 04:59:50 2013
@@ -9,6 +9,8 @@ set hive.merge.mapfiles=false;
 set hive.merge.mapredfiles=false; 
 set hive.auto.convert.sortmerge.join.bigtable.selection.policy=org.apache.hadoop.hive.ql.optimizer.LeftmostBigTableSelectorForAutoSMJ;
 
+set hive.auto.convert.sortmerge.join.to.mapjoin=true;
+
 -- Create two bucketed and sorted tables
 CREATE TABLE test_table1 (key INT, value STRING) PARTITIONED BY (ds STRING)
 CLUSTERED BY (key) SORTED BY (key) INTO 2 BUCKETS;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_3.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_3.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_3.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_3.q Fri Apr 26 04:59:50 2013
@@ -6,6 +6,8 @@ set hive.exec.reducers.max = 1;
 set hive.merge.mapfiles=false;
 set hive.merge.mapredfiles=false; 
 
+set hive.auto.convert.sortmerge.join.to.mapjoin=true;
+
 -- Create two bucketed and sorted tables
 CREATE TABLE test_table1 (key INT, value STRING) PARTITIONED BY (ds STRING)
 CLUSTERED BY (key) SORTED BY (key) INTO 2 BUCKETS;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_4.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_4.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_4.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_4.q Fri Apr 26 04:59:50 2013
@@ -9,6 +9,8 @@ set hive.merge.mapfiles=false;
 set hive.merge.mapredfiles=false; 
 set hive.auto.convert.sortmerge.join.bigtable.selection.policy=org.apache.hadoop.hive.ql.optimizer.LeftmostBigTableSelectorForAutoSMJ;
 
+set hive.auto.convert.sortmerge.join.to.mapjoin=true;
+
 -- Create two bucketed and sorted tables
 CREATE TABLE test_table1 (key INT, value STRING) PARTITIONED BY (ds STRING)
 CLUSTERED BY (key) SORTED BY (key) INTO 2 BUCKETS;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_5.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_5.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_5.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_5.q Fri Apr 26 04:59:50 2013
@@ -9,6 +9,8 @@ set hive.merge.mapfiles=false;
 set hive.merge.mapredfiles=false; 
 set hive.auto.convert.sortmerge.join.bigtable.selection.policy=org.apache.hadoop.hive.ql.optimizer.LeftmostBigTableSelectorForAutoSMJ;
 
+set hive.auto.convert.sortmerge.join.to.mapjoin=true;
+
 -- Create two bucketed and sorted tables
 CREATE TABLE test_table1 (key INT, value STRING) PARTITIONED BY (ds STRING)
 CLUSTERED BY (key) SORTED BY (key) INTO 2 BUCKETS;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_6.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_6.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_6.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_6.q Fri Apr 26 04:59:50 2013
@@ -9,6 +9,8 @@ set hive.merge.mapfiles=false;
 set hive.merge.mapredfiles=false; 
 set hive.auto.convert.sortmerge.join.bigtable.selection.policy=org.apache.hadoop.hive.ql.optimizer.LeftmostBigTableSelectorForAutoSMJ;
 
+set hive.auto.convert.sortmerge.join.to.mapjoin=true;
+
 -- Create two bucketed and sorted tables
 CREATE TABLE test_table1 (key INT, key2 INT, value STRING) PARTITIONED BY (ds STRING)
 CLUSTERED BY (key, key2) SORTED BY (key ASC, key2 DESC) INTO 2 BUCKETS;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_7.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_7.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_7.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_7.q Fri Apr 26 04:59:50 2013
@@ -9,6 +9,8 @@ set hive.merge.mapfiles=false;
 set hive.merge.mapredfiles=false; 
 set hive.auto.convert.sortmerge.join.bigtable.selection.policy=org.apache.hadoop.hive.ql.optimizer.LeftmostBigTableSelectorForAutoSMJ;
 
+set hive.auto.convert.sortmerge.join.to.mapjoin=true;
+
 -- Create two bucketed and sorted tables
 CREATE TABLE test_table1 (key INT, value STRING) PARTITIONED BY (ds STRING)
 CLUSTERED BY (key) SORTED BY (key) INTO 2 BUCKETS;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_8.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_8.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_8.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/bucketsortoptimize_insert_8.q Fri Apr 26 04:59:50 2013
@@ -9,6 +9,8 @@ set hive.merge.mapfiles=false;
 set hive.merge.mapredfiles=false; 
 set hive.auto.convert.sortmerge.join.bigtable.selection.policy=org.apache.hadoop.hive.ql.optimizer.LeftmostBigTableSelectorForAutoSMJ;
 
+set hive.auto.convert.sortmerge.join.to.mapjoin=true;
+
 -- Create two bucketed and sorted tables
 CREATE TABLE test_table1 (key INT, value STRING) PARTITIONED BY (ds STRING)
 CLUSTERED BY (key) SORTED BY (key) INTO 2 BUCKETS;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/database_drop.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/database_drop.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/database_drop.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/database_drop.q Fri Apr 26 04:59:50 2013
@@ -8,9 +8,9 @@ CREATE DATABASE db5;
 SHOW DATABASES;
 USE db5;
 
-dfs -mkdir ${system:test.tmp.dir}/dbcascade/temp;
+dfs ${system:test.dfs.mkdir} ${system:test.tmp.dir}/dbcascade/temp;
 dfs -rmr ${system:test.tmp.dir}/dbcascade;
-dfs -mkdir ${system:test.tmp.dir}/dbcascade;
+dfs ${system:test.dfs.mkdir} ${system:test.tmp.dir}/dbcascade;
 
 -- add a table, index and view
 CREATE TABLE temp_tbl (id INT, name STRING);
@@ -19,8 +19,8 @@ CREATE VIEW temp_tbl_view AS SELECT * FR
 CREATE INDEX idx1 ON TABLE temp_tbl(id) AS 'COMPACT' with DEFERRED REBUILD;
 ALTER INDEX idx1 ON temp_tbl REBUILD;
 
-dfs -mkdir ${system:test.tmp.dir}/dbcascade/temp_tbl2;
-dfs -mkdir ${system:test.tmp.dir}/dbcascade/temp_tbl2_idx2;
+dfs ${system:test.dfs.mkdir} ${system:test.tmp.dir}/dbcascade/temp_tbl2;
+dfs ${system:test.dfs.mkdir} ${system:test.tmp.dir}/dbcascade/temp_tbl2_idx2;
 -- add a table, index and view with a different storage location
 CREATE TABLE temp_tbl2 (id INT, name STRING) LOCATION 'file:${system:test.tmp.dir}/dbcascade/temp_tbl2';
 LOAD DATA LOCAL INPATH '../data/files/kv1.txt' into table temp_tbl2;
@@ -36,8 +36,8 @@ CREATE INDEX idx3 ON TABLE part_tab(id) 
 ALTER INDEX idx3 ON part_tab PARTITION (ds='2008-04-09') REBUILD;
 ALTER INDEX idx3 ON part_tab PARTITION (ds='2009-04-09') REBUILD;
 
-dfs -mkdir ${system:test.tmp.dir}/dbcascade/part_tab2;
-dfs -mkdir ${system:test.tmp.dir}/dbcascade/part_tab2_idx4;
+dfs ${system:test.dfs.mkdir} ${system:test.tmp.dir}/dbcascade/part_tab2;
+dfs ${system:test.dfs.mkdir} ${system:test.tmp.dir}/dbcascade/part_tab2_idx4;
 -- add a partitioned table, index and view with a different storage location
 CREATE TABLE part_tab2 (id INT, name STRING)  PARTITIONED BY (ds string)
 		LOCATION 'file:${system:test.tmp.dir}/dbcascade/part_tab2';
@@ -49,9 +49,9 @@ ALTER INDEX idx4 ON part_tab2 PARTITION 
 ALTER INDEX idx4 ON part_tab2 PARTITION (ds='2009-04-09') REBUILD;
 
 
-dfs -mkdir ${system:test.tmp.dir}/dbcascade/part_tab3;
-dfs -mkdir ${system:test.tmp.dir}/dbcascade/part_tab3_p1;
-dfs -mkdir ${system:test.tmp.dir}/dbcascade/part_tab3_idx5;
+dfs ${system:test.dfs.mkdir} ${system:test.tmp.dir}/dbcascade/part_tab3;
+dfs ${system:test.dfs.mkdir} ${system:test.tmp.dir}/dbcascade/part_tab3_p1;
+dfs ${system:test.dfs.mkdir} ${system:test.tmp.dir}/dbcascade/part_tab3_idx5;
 -- add a partitioned table, index and view with a different storage location
 CREATE TABLE part_tab3 (id INT, name STRING)  PARTITIONED BY (ds string)
 		LOCATION 'file:${system:test.tmp.dir}/dbcascade/part_tab3';
@@ -65,7 +65,7 @@ ALTER INDEX idx5 ON part_tab3 PARTITION 
 
 
 
-dfs -mkdir ${system:test.tmp.dir}/dbcascade/extab1;
+dfs ${system:test.dfs.mkdir} ${system:test.tmp.dir}/dbcascade/extab1;
 dfs -touchz ${system:test.tmp.dir}/dbcascade/extab1/file1.txt;
 -- add an external table
 CREATE EXTERNAL TABLE extab1(id INT, name STRING) ROW FORMAT

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_00_nonpart_empty.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_00_nonpart_empty.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_00_nonpart_empty.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_00_nonpart_empty.q Fri Apr 26 04:59:50 2013
@@ -5,7 +5,7 @@ set hive.test.mode.nosamplelist=exim_dep
 create table exim_department ( dep_id int comment "department id") 	
 	stored as textfile	
 	tblproperties("creator"="krishna");
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_01_nonpart.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_01_nonpart.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_01_nonpart.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_01_nonpart.q Fri Apr 26 04:59:50 2013
@@ -6,7 +6,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;		
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_02_00_part_empty.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_02_00_part_empty.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_02_00_part_empty.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_02_00_part_empty.q Fri Apr 26 04:59:50 2013
@@ -7,7 +7,7 @@ create table exim_employee ( emp_id int 
 	partitioned by (emp_country string comment "two char iso code", emp_state string comment "free text")
 	stored as textfile	
 	tblproperties("creator"="krishna");
-dfs -mkdir ../build/ql/test/data/exports/exim_employee/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_employee/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_employee;
 export table exim_employee to 'ql/test/data/exports/exim_employee';
 drop table exim_employee;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_02_part.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_02_part.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_02_part.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_02_part.q Fri Apr 26 04:59:50 2013
@@ -9,7 +9,7 @@ create table exim_employee ( emp_id int 
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" 
 	into table exim_employee partition (emp_country="in", emp_state="tn");		
-dfs -mkdir ../build/ql/test/data/exports/exim_employee/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_employee/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_employee;
 export table exim_employee to 'ql/test/data/exports/exim_employee';
 drop table exim_employee;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_03_nonpart_over_compat.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_03_nonpart_over_compat.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_03_nonpart_over_compat.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_03_nonpart_over_compat.q Fri Apr 26 04:59:50 2013
@@ -6,7 +6,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_04_all_part.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_04_all_part.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_04_all_part.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_04_all_part.q Fri Apr 26 04:59:50 2013
@@ -15,7 +15,7 @@ load data local inpath "../data/files/te
 	into table exim_employee partition (emp_country="us", emp_state="tn");	
 load data local inpath "../data/files/test.dat" 
 	into table exim_employee partition (emp_country="us", emp_state="ka");		
-dfs -mkdir ../build/ql/test/data/exports/exim_employee/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_employee/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_employee;
 export table exim_employee to 'ql/test/data/exports/exim_employee';
 drop table exim_employee;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_04_evolved_parts.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_04_evolved_parts.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_04_evolved_parts.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_04_evolved_parts.q Fri Apr 26 04:59:50 2013
@@ -19,7 +19,7 @@ alter table exim_employee set fileformat
 	outputformat "org.apache.hadoop.hive.ql.io.HiveSequenceFileOutputFormat";
 
 alter table exim_employee add partition (emp_country='in', emp_state='ka');
-dfs -mkdir ../build/ql/test/data/exports/exim_employee/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_employee/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_employee;
 export table exim_employee to 'ql/test/data/exports/exim_employee';
 drop table exim_employee;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_05_some_part.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_05_some_part.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_05_some_part.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_05_some_part.q Fri Apr 26 04:59:50 2013
@@ -15,7 +15,7 @@ load data local inpath "../data/files/te
 	into table exim_employee partition (emp_country="us", emp_state="tn");	
 load data local inpath "../data/files/test.dat" 
 	into table exim_employee partition (emp_country="us", emp_state="ka");		
-dfs -mkdir ../build/ql/test/data/exports/exim_employee/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_employee/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_employee;
 export table exim_employee partition (emp_state="ka") to 'ql/test/data/exports/exim_employee';
 drop table exim_employee;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_06_one_part.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_06_one_part.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_06_one_part.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_06_one_part.q Fri Apr 26 04:59:50 2013
@@ -15,7 +15,7 @@ load data local inpath "../data/files/te
 	into table exim_employee partition (emp_country="us", emp_state="tn");	
 load data local inpath "../data/files/test.dat" 
 	into table exim_employee partition (emp_country="us", emp_state="ka");		
-dfs -mkdir ../build/ql/test/data/exports/exim_employee/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_employee/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_employee;
 export table exim_employee partition (emp_country="in",emp_state="ka") to 'ql/test/data/exports/exim_employee';
 drop table exim_employee;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_07_all_part_over_nonoverlap.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_07_all_part_over_nonoverlap.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_07_all_part_over_nonoverlap.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_07_all_part_over_nonoverlap.q Fri Apr 26 04:59:50 2013
@@ -15,7 +15,7 @@ load data local inpath "../data/files/te
 	into table exim_employee partition (emp_country="us", emp_state="tn");	
 load data local inpath "../data/files/test.dat" 
 	into table exim_employee partition (emp_country="us", emp_state="ka");		
-dfs -mkdir ../build/ql/test/data/exports/exim_employee/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_employee/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_employee;
 export table exim_employee to 'ql/test/data/exports/exim_employee';
 drop table exim_employee;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_08_nonpart_rename.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_08_nonpart_rename.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_08_nonpart_rename.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_08_nonpart_rename.q Fri Apr 26 04:59:50 2013
@@ -6,7 +6,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;		
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_09_part_spec_nonoverlap.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_09_part_spec_nonoverlap.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_09_part_spec_nonoverlap.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_09_part_spec_nonoverlap.q Fri Apr 26 04:59:50 2013
@@ -15,7 +15,7 @@ load data local inpath "../data/files/te
 	into table exim_employee partition (emp_country="us", emp_state="tn");	
 load data local inpath "../data/files/test.dat" 
 	into table exim_employee partition (emp_country="us", emp_state="ka");		
-dfs -mkdir ../build/ql/test/data/exports/exim_employee/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_employee/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_employee;
 export table exim_employee to 'ql/test/data/exports/exim_employee';
 drop table exim_employee;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_10_external_managed.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_10_external_managed.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_10_external_managed.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_10_external_managed.q Fri Apr 26 04:59:50 2013
@@ -2,14 +2,14 @@ set hive.test.mode=true;
 set hive.test.mode.prefix=;
 set hive.test.mode.nosamplelist=exim_department,exim_employee;
 
-dfs -mkdir ../build/ql/test/data/tablestore/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/tablestore/exim_department/temp;
 dfs -rmr ../build/ql/test/data/tablestore/exim_department;
 create external table exim_department ( dep_id int comment "department id") 	
 	stored as textfile	
 	location 'ql/test/data/tablestore/exim_department'
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;		
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_11_managed_external.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_11_managed_external.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_11_managed_external.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_11_managed_external.q Fri Apr 26 04:59:50 2013
@@ -6,7 +6,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;		
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;

Modified: hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_12_external_location.q
URL: http://svn.apache.org/viewvc/hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_12_external_location.q?rev=1476039&r1=1476038&r2=1476039&view=diff
==============================================================================
--- hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_12_external_location.q (original)
+++ hive/branches/HIVE-4115/ql/src/test/queries/clientpositive/exim_12_external_location.q Fri Apr 26 04:59:50 2013
@@ -6,7 +6,7 @@ create table exim_department ( dep_id in
 	stored as textfile	
 	tblproperties("creator"="krishna");
 load data local inpath "../data/files/test.dat" into table exim_department;		
-dfs -mkdir ../build/ql/test/data/exports/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/exports/exim_department/temp;
 dfs -rmr ../build/ql/test/data/exports/exim_department;
 export table exim_department to 'ql/test/data/exports/exim_department';
 drop table exim_department;
@@ -14,7 +14,7 @@ drop table exim_department;
 create database importer;
 use importer;
 
-dfs -mkdir ../build/ql/test/data/tablestore/exim_department/temp;
+dfs ${system:test.dfs.mkdir} ../build/ql/test/data/tablestore/exim_department/temp;
 dfs -rmr ../build/ql/test/data/tablestore/exim_department;
 
 import external table exim_department from 'ql/test/data/exports/exim_department' 



Mime
View raw message