You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hive.apache.org by se...@apache.org on 2016/11/18 19:14:45 UTC

[1/2] hive git commit: HIVE-15148 : disallow loading data into bucketed tables (by default) (Sergey Shelukhin, reviewed by Ashutosh Chauhan)

Repository: hive
Updated Branches:
  refs/heads/master 8a1dcd7e6 -> 0a6fc6385


http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/results/clientnegative/strict_orderby.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientnegative/strict_orderby.q.out b/ql/src/test/results/clientnegative/strict_orderby.q.out
index 08c1062..3cc2a0c 100644
--- a/ql/src/test/results/clientnegative/strict_orderby.q.out
+++ b/ql/src/test/results/clientnegative/strict_orderby.q.out
@@ -1 +1 @@
-FAILED: SemanticException 4:47 Order by-s without limit are disabled for safety reasons. If you know what you are doing, please make sure that hive.strict.checks.large.query is set to false and that hive.mapred.mode is not set to 'strict' to enable them.. Error encountered near token 'key'
+FAILED: SemanticException 4:47 Order by-s without limit are disabled for safety reasons. If you know what you are doing, please sethive.strict.checks.large.query to false and that hive.mapred.mode is not set to 'strict' to proceed. Note that if you may get errors or incorrect results if you make a mistake while using some of the unsafe features.. Error encountered near token 'key'

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/results/clientnegative/strict_pruning.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientnegative/strict_pruning.q.out b/ql/src/test/results/clientnegative/strict_pruning.q.out
index d45a2b8..76b9083 100644
--- a/ql/src/test/results/clientnegative/strict_pruning.q.out
+++ b/ql/src/test/results/clientnegative/strict_pruning.q.out
@@ -1 +1 @@
-FAILED: SemanticException Queries against partitioned tables without a partition filter are disabled for safety reasons. If you know what you are doing, please make sure that hive.strict.checks.large.query is set to false and that hive.mapred.mode is not set to 'strict' to enable them. No partition predicate for Alias "srcpart" Table "srcpart"
+FAILED: SemanticException Queries against partitioned tables without a partition filter are disabled for safety reasons. If you know what you are doing, please sethive.strict.checks.large.query to false and that hive.mapred.mode is not set to 'strict' to proceed. Note that if you may get errors or incorrect results if you make a mistake while using some of the unsafe features. No partition predicate for Alias "srcpart" Table "srcpart"

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/results/clientpositive/sample2.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/sample2.q.out b/ql/src/test/results/clientpositive/sample2.q.out
index 096805d..06690df 100644
--- a/ql/src/test/results/clientpositive/sample2.q.out
+++ b/ql/src/test/results/clientpositive/sample2.q.out
@@ -81,7 +81,7 @@ STAGE PLANS:
       Path -> Partition:
 #### A masked pattern was here ####
           Partition
-            base file name: srcbucket0.txt
+            base file name: 000000_0
             input format: org.apache.hadoop.mapred.TextInputFormat
             output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
             properties:
@@ -126,7 +126,7 @@ STAGE PLANS:
               name: default.srcbucket
             name: default.srcbucket
       Truncated Path -> Alias:
-        /srcbucket/srcbucket0.txt [s]
+        /srcbucket/000000_0 [s]
 
   Stage: Stage-7
     Conditional Operator
@@ -362,496 +362,496 @@ POSTHOOK: query: SELECT dest1.* FROM dest1
 POSTHOOK: type: QUERY
 POSTHOOK: Input: default@dest1
 #### A masked pattern was here ####
-474	val_475
-62	val_63
-468	val_469
-272	val_273
-448	val_449
-246	val_247
-440	val_441
-278	val_279
-296	val_297
-428	val_429
-126	val_127
-106	val_107
-356	val_357
 490	val_491
-402	val_403
-128	val_129
-10	val_11
-226	val_227
-110	val_111
-0	val_1
-240	val_241
-286	val_287
-408	val_409
-476	val_477
-482	val_483
-48	val_49
-424	val_425
-226	val_227
-494	val_495
-488	val_489
-94	val_95
-50	val_51
-402	val_403
-128	val_129
-468	val_469
-314	val_315
-224	val_225
-344	val_345
-4	val_5
-206	val_207
-114	val_115
-56	val_57
-114	val_115
-254	val_255
-390	val_391
-304	val_305
-264	val_265
-196	val_197
-238	val_239
-20	val_21
-492	val_493
-82	val_83
-58	val_59
-86	val_87
-438	val_439
-360	val_361
-222	val_223
-42	val_43
-338	val_339
-68	val_69
-16	val_17
-492	val_493
-376	val_377
-120	val_121
-306	val_307
-426	val_427
-132	val_133
-446	val_447
-386	val_387
-388	val_389
-184	val_185
-284	val_285
-246	val_247
-262	val_263
-122	val_123
-438	val_439
-390	val_391
-352	val_353
-226	val_227
-328	val_329
-382	val_383
-342	val_343
-480	val_481
-102	val_103
-480	val_481
-318	val_319
-392	val_393
-476	val_477
-258	val_259
-174	val_175
-252	val_253
-114	val_115
-264	val_265
-48	val_49
-336	val_337
-340	val_341
-390	val_391
-484	val_485
-6	val_7
-260	val_261
-2	val_3
-170	val_171
-164	val_165
-118	val_119
-310	val_311
-104	val_105
-80	val_81
-326	val_327
-450	val_451
-140	val_141
-212	val_213
-308	val_309
-30	val_31
-358	val_359
-416	val_417
-42	val_43
-386	val_387
-454	val_455
-364	val_365
-20	val_21
-52	val_53
-40	val_41
-8	val_9
-168	val_169
-384	val_385
-324	val_325
-310	val_311
-206	val_207
-404	val_405
-206	val_207
-226	val_227
-262	val_263
-260	val_261
-328	val_329
-322	val_323
-122	val_123
-404	val_405
-384	val_385
-76	val_77
-116	val_117
-42	val_43
-104	val_105
-406	val_407
-32	val_33
-132	val_133
-192	val_193
-58	val_59
-70	val_71
 356	val_357
-352	val_353
-52	val_53
-330	val_331
-138	val_139
-160	val_161
-454	val_455
-76	val_77
-174	val_175
-412	val_413
-16	val_17
-204	val_205
+106	val_107
 126	val_127
-274	val_275
-374	val_375
-494	val_495
-216	val_217
-470	val_471
-196	val_197
-302	val_303
-450	val_451
-12	val_13
-398	val_399
-334	val_335
-384	val_385
-60	val_61
-442	val_443
-52	val_53
-404	val_405
-446	val_447
-300	val_301
-0	val_1
-268	val_269
-392	val_393
-104	val_105
-436	val_437
-156	val_157
-118	val_119
-172	val_173
-244	val_245
-6	val_7
-284	val_285
-164	val_165
-136	val_137
-462	val_463
-432	val_433
-496	val_497
-144	val_145
-408	val_409
-152	val_153
-382	val_383
-348	val_349
-122	val_123
-292	val_293
-182	val_183
-474	val_475
-310	val_311
-52	val_53
-486	val_487
-152	val_153
-378	val_379
-414	val_415
-256	val_257
-292	val_293
-412	val_413
-40	val_41
-478	val_479
-178	val_179
-100	val_101
-156	val_157
-228	val_229
-22	val_23
-248	val_249
-402	val_403
-62	val_63
-162	val_163
-244	val_245
-276	val_277
-46	val_47
-78	val_79
-134	val_135
-196	val_197
-410	val_411
-82	val_83
+428	val_429
+296	val_297
+278	val_279
 440	val_441
-100	val_101
-308	val_309
-430	val_431
+246	val_247
+448	val_449
+272	val_273
 468	val_469
-152	val_153
-138	val_139
-76	val_77
-300	val_301
-478	val_479
-118	val_119
-178	val_179
-242	val_243
-244	val_245
-238	val_238
-86	val_86
-278	val_278
-98	val_98
-484	val_484
-150	val_150
-224	val_224
-66	val_66
-128	val_128
-146	val_146
-406	val_406
-374	val_374
+62	val_63
+474	val_475
+200	val_200
+400	val_400
+90	val_90
+126	val_126
+222	val_222
+414	val_414
+194	val_194
+348	val_348
 152	val_152
-82	val_82
-166	val_166
-430	val_430
-252	val_252
-292	val_292
-338	val_338
-446	val_446
-394	val_394
-482	val_482
-174	val_174
-494	val_494
-466	val_466
-208	val_208
-174	val_174
-396	val_396
-162	val_162
-266	val_266
-342	val_342
-0	val_0
-128	val_128
-316	val_316
-302	val_302
-438	val_438
-170	val_170
-20	val_20
-378	val_378
-92	val_92
-72	val_72
-4	val_4
-280	val_280
-208	val_208
-356	val_356
-382	val_382
-498	val_498
-386	val_386
-192	val_192
-286	val_286
-176	val_176
-54	val_54
-138	val_138
-216	val_216
-430	val_430
-278	val_278
-176	val_176
-318	val_318
-332	val_332
-180	val_180
-284	val_284
-12	val_12
-230	val_230
-260	val_260
-404	val_404
-384	val_384
-272	val_272
-138	val_138
+448	val_448
+28	val_28
 84	val_84
+344	val_344
+18	val_18
 348	val_348
-466	val_466
-58	val_58
-8	val_8
-230	val_230
-208	val_208
-348	val_348
-24	val_24
-172	val_172
-42	val_42
-158	val_158
-496	val_496
-0	val_0
-322	val_322
-468	val_468
-454	val_454
-100	val_100
-298	val_298
-418	val_418
-96	val_96
-26	val_26
-230	val_230
-120	val_120
-404	val_404
-436	val_436
-156	val_156
-468	val_468
-308	val_308
-196	val_196
-288	val_288
-98	val_98
-282	val_282
-318	val_318
-318	val_318
-470	val_470
-316	val_316
-0	val_0
-490	val_490
-364	val_364
-118	val_118
-134	val_134
-282	val_282
-138	val_138
-238	val_238
-118	val_118
-72	val_72
-90	val_90
-10	val_10
-306	val_306
-224	val_224
-242	val_242
-392	val_392
-272	val_272
-242	val_242
-452	val_452
-226	val_226
-402	val_402
-396	val_396
-58	val_58
-336	val_336
-168	val_168
-34	val_34
-472	val_472
-322	val_322
-498	val_498
-160	val_160
-42	val_42
-430	val_430
+186	val_186
+362	val_362
 458	val_458
-78	val_78
-76	val_76
+146	val_146
+498	val_498
+298	val_298
+100	val_100
 492	val_492
-218	val_218
-228	val_228
-138	val_138
-30	val_30
-64	val_64
-468	val_468
-76	val_76
-74	val_74
-342	val_342
-230	val_230
-368	val_368
-296	val_296
-216	val_216
-344	val_344
-274	val_274
-116	val_116
+462	val_462
+18	val_18
+384	val_384
+134	val_134
+26	val_26
 256	val_256
-70	val_70
+384	val_384
+454	val_454
+406	val_406
+462	val_462
+214	val_214
+172	val_172
+136	val_136
 480	val_480
-288	val_288
-244	val_244
+460	val_460
+310	val_310
+468	val_468
+178	val_178
+478	val_478
+230	val_230
+120	val_120
+444	val_444
+248	val_248
+360	val_360
+200	val_200
+414	val_414
 438	val_438
-128	val_128
-432	val_432
-202	val_202
-316	val_316
-280	val_280
-2	val_2
-80	val_80
-44	val_44
+70	val_70
 104	val_104
-466	val_466
-366	val_366
-406	val_406
-190	val_190
-406	val_406
-114	val_114
-258	val_258
-90	val_90
-262	val_262
-348	val_348
+24	val_24
+480	val_480
+70	val_70
+382	val_382
 424	val_424
-12	val_12
-396	val_396
 164	val_164
-454	val_454
-478	val_478
 298	val_298
+478	val_478
+454	val_454
 164	val_164
+396	val_396
+12	val_12
 424	val_424
-382	val_382
-70	val_70
-480	val_480
-24	val_24
+348	val_348
+262	val_262
+90	val_90
+258	val_258
+114	val_114
+406	val_406
+190	val_190
+406	val_406
+366	val_366
+466	val_466
 104	val_104
-70	val_70
+44	val_44
+80	val_80
+2	val_2
+280	val_280
+316	val_316
+202	val_202
+432	val_432
+128	val_128
 438	val_438
-414	val_414
-200	val_200
-360	val_360
-248	val_248
-444	val_444
-120	val_120
-230	val_230
-478	val_478
-178	val_178
-468	val_468
-310	val_310
-460	val_460
+244	val_244
+288	val_288
 480	val_480
-136	val_136
-172	val_172
-214	val_214
-462	val_462
-406	val_406
-454	val_454
-384	val_384
+70	val_70
 256	val_256
-26	val_26
-134	val_134
-384	val_384
-18	val_18
-462	val_462
+116	val_116
+274	val_274
+344	val_344
+216	val_216
+296	val_296
+368	val_368
+230	val_230
+342	val_342
+74	val_74
+76	val_76
+468	val_468
+64	val_64
+30	val_30
+138	val_138
+228	val_228
+218	val_218
 492	val_492
-100	val_100
-298	val_298
-498	val_498
-146	val_146
+76	val_76
+78	val_78
 458	val_458
-362	val_362
-186	val_186
+430	val_430
+42	val_42
+160	val_160
+498	val_498
+322	val_322
+472	val_472
+34	val_34
+168	val_168
+336	val_336
+58	val_58
+396	val_396
+402	val_402
+226	val_226
+452	val_452
+242	val_242
+272	val_272
+392	val_392
+242	val_242
+224	val_224
+306	val_306
+10	val_10
+90	val_90
+72	val_72
+118	val_118
+238	val_238
+138	val_138
+282	val_282
+134	val_134
+118	val_118
+364	val_364
+490	val_490
+0	val_0
+316	val_316
+470	val_470
+318	val_318
+318	val_318
+282	val_282
+98	val_98
+288	val_288
+196	val_196
+308	val_308
+468	val_468
+156	val_156
+436	val_436
+404	val_404
+120	val_120
+230	val_230
+26	val_26
+96	val_96
+418	val_418
+298	val_298
+100	val_100
+454	val_454
+468	val_468
+322	val_322
+0	val_0
+496	val_496
+158	val_158
+42	val_42
+172	val_172
+24	val_24
+348	val_348
+208	val_208
+230	val_230
+8	val_8
+58	val_58
+466	val_466
 348	val_348
-18	val_18
-344	val_344
 84	val_84
-28	val_28
-448	val_448
+138	val_138
+272	val_272
+384	val_384
+404	val_404
+260	val_260
+230	val_230
+12	val_12
+284	val_284
+180	val_180
+332	val_332
+318	val_318
+176	val_176
+278	val_278
+430	val_430
+216	val_216
+138	val_138
+54	val_54
+176	val_176
+286	val_286
+192	val_192
+386	val_386
+498	val_498
+382	val_382
+356	val_356
+208	val_208
+280	val_280
+4	val_4
+72	val_72
+92	val_92
+378	val_378
+20	val_20
+170	val_170
+438	val_438
+302	val_302
+316	val_316
+128	val_128
+0	val_0
+342	val_342
+266	val_266
+162	val_162
+396	val_396
+174	val_174
+208	val_208
+466	val_466
+494	val_494
+174	val_174
+482	val_482
+394	val_394
+446	val_446
+338	val_338
+292	val_292
+252	val_252
+430	val_430
+166	val_166
+82	val_82
 152	val_152
-348	val_348
-194	val_194
-414	val_414
-222	val_222
-126	val_126
-90	val_90
-400	val_400
-200	val_200
+374	val_374
+406	val_406
+146	val_146
+128	val_128
+66	val_66
+224	val_224
+150	val_150
+484	val_484
+98	val_98
+278	val_278
+86	val_86
+238	val_238
+244	val_245
+242	val_243
+178	val_179
+118	val_119
+478	val_479
+300	val_301
+76	val_77
+138	val_139
+152	val_153
+468	val_469
+430	val_431
+308	val_309
+100	val_101
+440	val_441
+82	val_83
+410	val_411
+196	val_197
+134	val_135
+78	val_79
+46	val_47
+276	val_277
+244	val_245
+162	val_163
+62	val_63
+402	val_403
+248	val_249
+22	val_23
+228	val_229
+156	val_157
+100	val_101
+178	val_179
+478	val_479
+40	val_41
+412	val_413
+292	val_293
+256	val_257
+414	val_415
+378	val_379
+152	val_153
+486	val_487
+52	val_53
+310	val_311
+474	val_475
+182	val_183
+292	val_293
+122	val_123
+348	val_349
+382	val_383
+152	val_153
+408	val_409
+144	val_145
+496	val_497
+432	val_433
+462	val_463
+136	val_137
+164	val_165
+284	val_285
+6	val_7
+244	val_245
+172	val_173
+118	val_119
+156	val_157
+436	val_437
+104	val_105
+392	val_393
+268	val_269
+0	val_1
+300	val_301
+446	val_447
+404	val_405
+52	val_53
+442	val_443
+60	val_61
+384	val_385
+334	val_335
+398	val_399
+12	val_13
+450	val_451
+302	val_303
+196	val_197
+470	val_471
+216	val_217
+494	val_495
+374	val_375
+274	val_275
+126	val_127
+204	val_205
+16	val_17
+412	val_413
+174	val_175
+76	val_77
+454	val_455
+160	val_161
+138	val_139
+330	val_331
+52	val_53
+352	val_353
+356	val_357
+70	val_71
+58	val_59
+192	val_193
+132	val_133
+32	val_33
+406	val_407
+104	val_105
+42	val_43
+116	val_117
+76	val_77
+384	val_385
+404	val_405
+122	val_123
+322	val_323
+328	val_329
+260	val_261
+262	val_263
+226	val_227
+206	val_207
+404	val_405
+206	val_207
+310	val_311
+324	val_325
+384	val_385
+168	val_169
+8	val_9
+40	val_41
+52	val_53
+20	val_21
+364	val_365
+454	val_455
+386	val_387
+42	val_43
+416	val_417
+358	val_359
+30	val_31
+308	val_309
+212	val_213
+140	val_141
+450	val_451
+326	val_327
+80	val_81
+104	val_105
+310	val_311
+118	val_119
+164	val_165
+170	val_171
+2	val_3
+260	val_261
+6	val_7
+484	val_485
+390	val_391
+340	val_341
+336	val_337
+48	val_49
+264	val_265
+114	val_115
+252	val_253
+174	val_175
+258	val_259
+476	val_477
+392	val_393
+318	val_319
+480	val_481
+102	val_103
+480	val_481
+342	val_343
+382	val_383
+328	val_329
+226	val_227
+352	val_353
+390	val_391
+438	val_439
+122	val_123
+262	val_263
+246	val_247
+284	val_285
+184	val_185
+388	val_389
+386	val_387
+446	val_447
+132	val_133
+426	val_427
+306	val_307
+120	val_121
+376	val_377
+492	val_493
+16	val_17
+68	val_69
+338	val_339
+42	val_43
+222	val_223
+360	val_361
+438	val_439
+86	val_87
+58	val_59
+82	val_83
+492	val_493
+20	val_21
+238	val_239
+196	val_197
+264	val_265
+304	val_305
+390	val_391
+254	val_255
+114	val_115
+56	val_57
+114	val_115
+206	val_207
+4	val_5
+344	val_345
+224	val_225
+314	val_315
+468	val_469
+128	val_129
+402	val_403
+50	val_51
+94	val_95
+488	val_489
+494	val_495
+226	val_227
+424	val_425
+48	val_49
+482	val_483
+476	val_477
+408	val_409
+286	val_287
+240	val_241
+0	val_1
+110	val_111
+226	val_227
+10	val_11
+128	val_129
+402	val_403

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/results/clientpositive/sample4.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/sample4.q.out b/ql/src/test/results/clientpositive/sample4.q.out
index 72395c9..4652dd8 100644
--- a/ql/src/test/results/clientpositive/sample4.q.out
+++ b/ql/src/test/results/clientpositive/sample4.q.out
@@ -81,7 +81,7 @@ STAGE PLANS:
       Path -> Partition:
 #### A masked pattern was here ####
           Partition
-            base file name: srcbucket0.txt
+            base file name: 000000_0
             input format: org.apache.hadoop.mapred.TextInputFormat
             output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
             properties:
@@ -126,7 +126,7 @@ STAGE PLANS:
               name: default.srcbucket
             name: default.srcbucket
       Truncated Path -> Alias:
-        /srcbucket/srcbucket0.txt [s]
+        /srcbucket/000000_0 [s]
 
   Stage: Stage-7
     Conditional Operator
@@ -362,496 +362,496 @@ POSTHOOK: query: SELECT dest1.* FROM dest1
 POSTHOOK: type: QUERY
 POSTHOOK: Input: default@dest1
 #### A masked pattern was here ####
-474	val_475
-62	val_63
-468	val_469
-272	val_273
-448	val_449
-246	val_247
-440	val_441
-278	val_279
-296	val_297
-428	val_429
-126	val_127
-106	val_107
-356	val_357
 490	val_491
-402	val_403
-128	val_129
-10	val_11
-226	val_227
-110	val_111
-0	val_1
-240	val_241
-286	val_287
-408	val_409
-476	val_477
-482	val_483
-48	val_49
-424	val_425
-226	val_227
-494	val_495
-488	val_489
-94	val_95
-50	val_51
-402	val_403
-128	val_129
-468	val_469
-314	val_315
-224	val_225
-344	val_345
-4	val_5
-206	val_207
-114	val_115
-56	val_57
-114	val_115
-254	val_255
-390	val_391
-304	val_305
-264	val_265
-196	val_197
-238	val_239
-20	val_21
-492	val_493
-82	val_83
-58	val_59
-86	val_87
-438	val_439
-360	val_361
-222	val_223
-42	val_43
-338	val_339
-68	val_69
-16	val_17
-492	val_493
-376	val_377
-120	val_121
-306	val_307
-426	val_427
-132	val_133
-446	val_447
-386	val_387
-388	val_389
-184	val_185
-284	val_285
-246	val_247
-262	val_263
-122	val_123
-438	val_439
-390	val_391
-352	val_353
-226	val_227
-328	val_329
-382	val_383
-342	val_343
-480	val_481
-102	val_103
-480	val_481
-318	val_319
-392	val_393
-476	val_477
-258	val_259
-174	val_175
-252	val_253
-114	val_115
-264	val_265
-48	val_49
-336	val_337
-340	val_341
-390	val_391
-484	val_485
-6	val_7
-260	val_261
-2	val_3
-170	val_171
-164	val_165
-118	val_119
-310	val_311
-104	val_105
-80	val_81
-326	val_327
-450	val_451
-140	val_141
-212	val_213
-308	val_309
-30	val_31
-358	val_359
-416	val_417
-42	val_43
-386	val_387
-454	val_455
-364	val_365
-20	val_21
-52	val_53
-40	val_41
-8	val_9
-168	val_169
-384	val_385
-324	val_325
-310	val_311
-206	val_207
-404	val_405
-206	val_207
-226	val_227
-262	val_263
-260	val_261
-328	val_329
-322	val_323
-122	val_123
-404	val_405
-384	val_385
-76	val_77
-116	val_117
-42	val_43
-104	val_105
-406	val_407
-32	val_33
-132	val_133
-192	val_193
-58	val_59
-70	val_71
 356	val_357
-352	val_353
-52	val_53
-330	val_331
-138	val_139
-160	val_161
-454	val_455
-76	val_77
-174	val_175
-412	val_413
-16	val_17
-204	val_205
+106	val_107
 126	val_127
-274	val_275
-374	val_375
-494	val_495
-216	val_217
-470	val_471
-196	val_197
-302	val_303
-450	val_451
-12	val_13
-398	val_399
-334	val_335
-384	val_385
-60	val_61
-442	val_443
-52	val_53
-404	val_405
-446	val_447
-300	val_301
-0	val_1
-268	val_269
-392	val_393
-104	val_105
-436	val_437
-156	val_157
-118	val_119
-172	val_173
-244	val_245
-6	val_7
-284	val_285
-164	val_165
-136	val_137
-462	val_463
-432	val_433
-496	val_497
-144	val_145
-408	val_409
-152	val_153
-382	val_383
-348	val_349
-122	val_123
-292	val_293
-182	val_183
-474	val_475
-310	val_311
-52	val_53
-486	val_487
-152	val_153
-378	val_379
-414	val_415
-256	val_257
-292	val_293
-412	val_413
-40	val_41
-478	val_479
-178	val_179
-100	val_101
-156	val_157
-228	val_229
-22	val_23
-248	val_249
-402	val_403
-62	val_63
-162	val_163
-244	val_245
-276	val_277
-46	val_47
-78	val_79
-134	val_135
-196	val_197
-410	val_411
-82	val_83
+428	val_429
+296	val_297
+278	val_279
 440	val_441
-100	val_101
-308	val_309
-430	val_431
+246	val_247
+448	val_449
+272	val_273
 468	val_469
-152	val_153
-138	val_139
-76	val_77
-300	val_301
-478	val_479
-118	val_119
-178	val_179
-242	val_243
-244	val_245
-238	val_238
-86	val_86
-278	val_278
-98	val_98
-484	val_484
-150	val_150
-224	val_224
-66	val_66
-128	val_128
-146	val_146
-406	val_406
-374	val_374
+62	val_63
+474	val_475
+200	val_200
+400	val_400
+90	val_90
+126	val_126
+222	val_222
+414	val_414
+194	val_194
+348	val_348
 152	val_152
-82	val_82
-166	val_166
-430	val_430
-252	val_252
-292	val_292
-338	val_338
-446	val_446
-394	val_394
-482	val_482
-174	val_174
-494	val_494
-466	val_466
-208	val_208
-174	val_174
-396	val_396
-162	val_162
-266	val_266
-342	val_342
-0	val_0
-128	val_128
-316	val_316
-302	val_302
-438	val_438
-170	val_170
-20	val_20
-378	val_378
-92	val_92
-72	val_72
-4	val_4
-280	val_280
-208	val_208
-356	val_356
-382	val_382
-498	val_498
-386	val_386
-192	val_192
-286	val_286
-176	val_176
-54	val_54
-138	val_138
-216	val_216
-430	val_430
-278	val_278
-176	val_176
-318	val_318
-332	val_332
-180	val_180
-284	val_284
-12	val_12
-230	val_230
-260	val_260
-404	val_404
-384	val_384
-272	val_272
-138	val_138
+448	val_448
+28	val_28
 84	val_84
+344	val_344
+18	val_18
 348	val_348
-466	val_466
-58	val_58
-8	val_8
-230	val_230
-208	val_208
-348	val_348
-24	val_24
-172	val_172
-42	val_42
-158	val_158
-496	val_496
-0	val_0
-322	val_322
-468	val_468
-454	val_454
-100	val_100
-298	val_298
-418	val_418
-96	val_96
-26	val_26
-230	val_230
-120	val_120
-404	val_404
-436	val_436
-156	val_156
-468	val_468
-308	val_308
-196	val_196
-288	val_288
-98	val_98
-282	val_282
-318	val_318
-318	val_318
-470	val_470
-316	val_316
-0	val_0
-490	val_490
-364	val_364
-118	val_118
-134	val_134
-282	val_282
-138	val_138
-238	val_238
-118	val_118
-72	val_72
-90	val_90
-10	val_10
-306	val_306
-224	val_224
-242	val_242
-392	val_392
-272	val_272
-242	val_242
-452	val_452
-226	val_226
-402	val_402
-396	val_396
-58	val_58
-336	val_336
-168	val_168
-34	val_34
-472	val_472
-322	val_322
-498	val_498
-160	val_160
-42	val_42
-430	val_430
+186	val_186
+362	val_362
 458	val_458
-78	val_78
-76	val_76
+146	val_146
+498	val_498
+298	val_298
+100	val_100
 492	val_492
-218	val_218
-228	val_228
-138	val_138
-30	val_30
-64	val_64
-468	val_468
-76	val_76
-74	val_74
-342	val_342
-230	val_230
-368	val_368
-296	val_296
-216	val_216
-344	val_344
-274	val_274
-116	val_116
+462	val_462
+18	val_18
+384	val_384
+134	val_134
+26	val_26
 256	val_256
-70	val_70
+384	val_384
+454	val_454
+406	val_406
+462	val_462
+214	val_214
+172	val_172
+136	val_136
 480	val_480
-288	val_288
-244	val_244
+460	val_460
+310	val_310
+468	val_468
+178	val_178
+478	val_478
+230	val_230
+120	val_120
+444	val_444
+248	val_248
+360	val_360
+200	val_200
+414	val_414
 438	val_438
-128	val_128
-432	val_432
-202	val_202
-316	val_316
-280	val_280
-2	val_2
-80	val_80
-44	val_44
+70	val_70
 104	val_104
-466	val_466
-366	val_366
-406	val_406
-190	val_190
-406	val_406
-114	val_114
-258	val_258
-90	val_90
-262	val_262
-348	val_348
+24	val_24
+480	val_480
+70	val_70
+382	val_382
 424	val_424
-12	val_12
-396	val_396
 164	val_164
-454	val_454
-478	val_478
 298	val_298
+478	val_478
+454	val_454
 164	val_164
+396	val_396
+12	val_12
 424	val_424
-382	val_382
-70	val_70
-480	val_480
-24	val_24
+348	val_348
+262	val_262
+90	val_90
+258	val_258
+114	val_114
+406	val_406
+190	val_190
+406	val_406
+366	val_366
+466	val_466
 104	val_104
-70	val_70
+44	val_44
+80	val_80
+2	val_2
+280	val_280
+316	val_316
+202	val_202
+432	val_432
+128	val_128
 438	val_438
-414	val_414
-200	val_200
-360	val_360
-248	val_248
-444	val_444
-120	val_120
-230	val_230
-478	val_478
-178	val_178
-468	val_468
-310	val_310
-460	val_460
+244	val_244
+288	val_288
 480	val_480
-136	val_136
-172	val_172
-214	val_214
-462	val_462
-406	val_406
-454	val_454
-384	val_384
+70	val_70
 256	val_256
-26	val_26
-134	val_134
-384	val_384
-18	val_18
-462	val_462
+116	val_116
+274	val_274
+344	val_344
+216	val_216
+296	val_296
+368	val_368
+230	val_230
+342	val_342
+74	val_74
+76	val_76
+468	val_468
+64	val_64
+30	val_30
+138	val_138
+228	val_228
+218	val_218
 492	val_492
-100	val_100
-298	val_298
-498	val_498
-146	val_146
+76	val_76
+78	val_78
 458	val_458
-362	val_362
-186	val_186
+430	val_430
+42	val_42
+160	val_160
+498	val_498
+322	val_322
+472	val_472
+34	val_34
+168	val_168
+336	val_336
+58	val_58
+396	val_396
+402	val_402
+226	val_226
+452	val_452
+242	val_242
+272	val_272
+392	val_392
+242	val_242
+224	val_224
+306	val_306
+10	val_10
+90	val_90
+72	val_72
+118	val_118
+238	val_238
+138	val_138
+282	val_282
+134	val_134
+118	val_118
+364	val_364
+490	val_490
+0	val_0
+316	val_316
+470	val_470
+318	val_318
+318	val_318
+282	val_282
+98	val_98
+288	val_288
+196	val_196
+308	val_308
+468	val_468
+156	val_156
+436	val_436
+404	val_404
+120	val_120
+230	val_230
+26	val_26
+96	val_96
+418	val_418
+298	val_298
+100	val_100
+454	val_454
+468	val_468
+322	val_322
+0	val_0
+496	val_496
+158	val_158
+42	val_42
+172	val_172
+24	val_24
+348	val_348
+208	val_208
+230	val_230
+8	val_8
+58	val_58
+466	val_466
 348	val_348
-18	val_18
-344	val_344
 84	val_84
-28	val_28
-448	val_448
+138	val_138
+272	val_272
+384	val_384
+404	val_404
+260	val_260
+230	val_230
+12	val_12
+284	val_284
+180	val_180
+332	val_332
+318	val_318
+176	val_176
+278	val_278
+430	val_430
+216	val_216
+138	val_138
+54	val_54
+176	val_176
+286	val_286
+192	val_192
+386	val_386
+498	val_498
+382	val_382
+356	val_356
+208	val_208
+280	val_280
+4	val_4
+72	val_72
+92	val_92
+378	val_378
+20	val_20
+170	val_170
+438	val_438
+302	val_302
+316	val_316
+128	val_128
+0	val_0
+342	val_342
+266	val_266
+162	val_162
+396	val_396
+174	val_174
+208	val_208
+466	val_466
+494	val_494
+174	val_174
+482	val_482
+394	val_394
+446	val_446
+338	val_338
+292	val_292
+252	val_252
+430	val_430
+166	val_166
+82	val_82
 152	val_152
-348	val_348
-194	val_194
-414	val_414
-222	val_222
-126	val_126
-90	val_90
-400	val_400
-200	val_200
+374	val_374
+406	val_406
+146	val_146
+128	val_128
+66	val_66
+224	val_224
+150	val_150
+484	val_484
+98	val_98
+278	val_278
+86	val_86
+238	val_238
+244	val_245
+242	val_243
+178	val_179
+118	val_119
+478	val_479
+300	val_301
+76	val_77
+138	val_139
+152	val_153
+468	val_469
+430	val_431
+308	val_309
+100	val_101
+440	val_441
+82	val_83
+410	val_411
+196	val_197
+134	val_135
+78	val_79
+46	val_47
+276	val_277
+244	val_245
+162	val_163
+62	val_63
+402	val_403
+248	val_249
+22	val_23
+228	val_229
+156	val_157
+100	val_101
+178	val_179
+478	val_479
+40	val_41
+412	val_413
+292	val_293
+256	val_257
+414	val_415
+378	val_379
+152	val_153
+486	val_487
+52	val_53
+310	val_311
+474	val_475
+182	val_183
+292	val_293
+122	val_123
+348	val_349
+382	val_383
+152	val_153
+408	val_409
+144	val_145
+496	val_497
+432	val_433
+462	val_463
+136	val_137
+164	val_165
+284	val_285
+6	val_7
+244	val_245
+172	val_173
+118	val_119
+156	val_157
+436	val_437
+104	val_105
+392	val_393
+268	val_269
+0	val_1
+300	val_301
+446	val_447
+404	val_405
+52	val_53
+442	val_443
+60	val_61
+384	val_385
+334	val_335
+398	val_399
+12	val_13
+450	val_451
+302	val_303
+196	val_197
+470	val_471
+216	val_217
+494	val_495
+374	val_375
+274	val_275
+126	val_127
+204	val_205
+16	val_17
+412	val_413
+174	val_175
+76	val_77
+454	val_455
+160	val_161
+138	val_139
+330	val_331
+52	val_53
+352	val_353
+356	val_357
+70	val_71
+58	val_59
+192	val_193
+132	val_133
+32	val_33
+406	val_407
+104	val_105
+42	val_43
+116	val_117
+76	val_77
+384	val_385
+404	val_405
+122	val_123
+322	val_323
+328	val_329
+260	val_261
+262	val_263
+226	val_227
+206	val_207
+404	val_405
+206	val_207
+310	val_311
+324	val_325
+384	val_385
+168	val_169
+8	val_9
+40	val_41
+52	val_53
+20	val_21
+364	val_365
+454	val_455
+386	val_387
+42	val_43
+416	val_417
+358	val_359
+30	val_31
+308	val_309
+212	val_213
+140	val_141
+450	val_451
+326	val_327
+80	val_81
+104	val_105
+310	val_311
+118	val_119
+164	val_165
+170	val_171
+2	val_3
+260	val_261
+6	val_7
+484	val_485
+390	val_391
+340	val_341
+336	val_337
+48	val_49
+264	val_265
+114	val_115
+252	val_253
+174	val_175
+258	val_259
+476	val_477
+392	val_393
+318	val_319
+480	val_481
+102	val_103
+480	val_481
+342	val_343
+382	val_383
+328	val_329
+226	val_227
+352	val_353
+390	val_391
+438	val_439
+122	val_123
+262	val_263
+246	val_247
+284	val_285
+184	val_185
+388	val_389
+386	val_387
+446	val_447
+132	val_133
+426	val_427
+306	val_307
+120	val_121
+376	val_377
+492	val_493
+16	val_17
+68	val_69
+338	val_339
+42	val_43
+222	val_223
+360	val_361
+438	val_439
+86	val_87
+58	val_59
+82	val_83
+492	val_493
+20	val_21
+238	val_239
+196	val_197
+264	val_265
+304	val_305
+390	val_391
+254	val_255
+114	val_115
+56	val_57
+114	val_115
+206	val_207
+4	val_5
+344	val_345
+224	val_225
+314	val_315
+468	val_469
+128	val_129
+402	val_403
+50	val_51
+94	val_95
+488	val_489
+494	val_495
+226	val_227
+424	val_425
+48	val_49
+482	val_483
+476	val_477
+408	val_409
+286	val_287
+240	val_241
+0	val_1
+110	val_111
+226	val_227
+10	val_11
+128	val_129
+402	val_403

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/results/clientpositive/sample6.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/sample6.q.out b/ql/src/test/results/clientpositive/sample6.q.out
index a34258d..475fe02 100644
--- a/ql/src/test/results/clientpositive/sample6.q.out
+++ b/ql/src/test/results/clientpositive/sample6.q.out
@@ -79,7 +79,7 @@ STAGE PLANS:
       Path -> Partition:
 #### A masked pattern was here ####
           Partition
-            base file name: srcbucket0.txt
+            base file name: 000000_0
             input format: org.apache.hadoop.mapred.TextInputFormat
             output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
             properties:
@@ -124,7 +124,7 @@ STAGE PLANS:
               name: default.srcbucket
             name: default.srcbucket
       Truncated Path -> Alias:
-        /srcbucket/srcbucket0.txt [s]
+        /srcbucket/000000_0 [s]
 
   Stage: Stage-7
     Conditional Operator
@@ -360,255 +360,255 @@ POSTHOOK: query: SELECT dest1.* FROM dest1
 POSTHOOK: type: QUERY
 POSTHOOK: Input: default@dest1
 #### A masked pattern was here ####
-468	val_469
-272	val_273
-448	val_449
-440	val_441
-296	val_297
-428	val_429
 356	val_357
-128	val_129
-0	val_1
-240	val_241
-408	val_409
-476	val_477
-48	val_49
-424	val_425
-488	val_489
-128	val_129
-468	val_469
-224	val_225
-344	val_345
-4	val_5
-56	val_57
-304	val_305
-264	val_265
-196	val_197
-20	val_21
-492	val_493
-360	val_361
-68	val_69
-16	val_17
-492	val_493
-376	val_377
-120	val_121
-132	val_133
-388	val_389
-184	val_185
-284	val_285
-352	val_353
-328	val_329
-480	val_481
-480	val_481
-392	val_393
-476	val_477
-252	val_253
-264	val_265
-48	val_49
-336	val_337
-340	val_341
-484	val_485
-260	val_261
-164	val_165
-104	val_105
-80	val_81
-140	val_141
-212	val_213
-308	val_309
-416	val_417
-364	val_365
-20	val_21
-52	val_53
-40	val_41
-8	val_9
-168	val_169
-384	val_385
-324	val_325
-404	val_405
-260	val_261
-328	val_329
-404	val_405
-384	val_385
-76	val_77
-116	val_117
-104	val_105
-32	val_33
-132	val_133
-192	val_193
-356	val_357
-352	val_353
-52	val_53
-160	val_161
-76	val_77
-412	val_413
-16	val_17
-204	val_205
-216	val_217
-196	val_197
-12	val_13
-384	val_385
-60	val_61
-52	val_53
-404	val_405
-300	val_301
-0	val_1
-268	val_269
-392	val_393
-104	val_105
-436	val_437
-156	val_157
-172	val_173
-244	val_245
-284	val_285
-164	val_165
-136	val_137
-432	val_433
-496	val_497
-144	val_145
-408	val_409
-152	val_153
-348	val_349
-292	val_293
-52	val_53
-152	val_153
-256	val_257
-292	val_293
-412	val_413
-40	val_41
-100	val_101
-156	val_157
-228	val_229
-248	val_249
-244	val_245
-276	val_277
-196	val_197
+428	val_429
+296	val_297
 440	val_441
-100	val_101
-308	val_309
+448	val_449
+272	val_273
 468	val_469
-152	val_153
-76	val_77
-300	val_301
-244	val_245
-484	val_484
-224	val_224
-128	val_128
+200	val_200
+400	val_400
+348	val_348
 152	val_152
-252	val_252
-292	val_292
-208	val_208
-396	val_396
-0	val_0
-128	val_128
-316	val_316
-20	val_20
-92	val_92
-72	val_72
-4	val_4
-280	val_280
-208	val_208
-356	val_356
-192	val_192
-176	val_176
-216	val_216
-176	val_176
-332	val_332
-180	val_180
-284	val_284
-12	val_12
-260	val_260
-404	val_404
-384	val_384
-272	val_272
+448	val_448
+28	val_28
 84	val_84
+344	val_344
 348	val_348
-8	val_8
-208	val_208
-348	val_348
-24	val_24
-172	val_172
-496	val_496
-0	val_0
-468	val_468
 100	val_100
-96	val_96
-120	val_120
-404	val_404
-436	val_436
-156	val_156
-468	val_468
-308	val_308
-196	val_196
-288	val_288
-316	val_316
-0	val_0
-364	val_364
-72	val_72
-224	val_224
-392	val_392
-272	val_272
-452	val_452
-396	val_396
-336	val_336
-168	val_168
-472	val_472
-160	val_160
-76	val_76
 492	val_492
-228	val_228
-64	val_64
-468	val_468
-76	val_76
-368	val_368
-296	val_296
-216	val_216
-344	val_344
-116	val_116
+384	val_384
 256	val_256
+384	val_384
+172	val_172
+136	val_136
 480	val_480
-288	val_288
-244	val_244
-128	val_128
-432	val_432
-316	val_316
-280	val_280
-80	val_80
-44	val_44
+460	val_460
+468	val_468
+120	val_120
+444	val_444
+248	val_248
+360	val_360
+200	val_200
 104	val_104
-348	val_348
+24	val_24
+480	val_480
 424	val_424
-12	val_12
-396	val_396
 164	val_164
 164	val_164
+396	val_396
+12	val_12
 424	val_424
-480	val_480
-24	val_24
+348	val_348
 104	val_104
-200	val_200
-360	val_360
-248	val_248
-444	val_444
-120	val_120
-468	val_468
-460	val_460
+44	val_44
+80	val_80
+280	val_280
+316	val_316
+432	val_432
+128	val_128
+244	val_244
+288	val_288
 480	val_480
-136	val_136
-172	val_172
-384	val_384
 256	val_256
-384	val_384
+116	val_116
+344	val_344
+216	val_216
+296	val_296
+368	val_368
+76	val_76
+468	val_468
+64	val_64
+228	val_228
 492	val_492
+76	val_76
+160	val_160
+472	val_472
+168	val_168
+336	val_336
+396	val_396
+452	val_452
+272	val_272
+392	val_392
+224	val_224
+72	val_72
+364	val_364
+0	val_0
+316	val_316
+288	val_288
+196	val_196
+308	val_308
+468	val_468
+156	val_156
+436	val_436
+404	val_404
+120	val_120
+96	val_96
 100	val_100
+468	val_468
+0	val_0
+496	val_496
+172	val_172
+24	val_24
+348	val_348
+208	val_208
+8	val_8
 348	val_348
-344	val_344
 84	val_84
-28	val_28
-448	val_448
+272	val_272
+384	val_384
+404	val_404
+260	val_260
+12	val_12
+284	val_284
+180	val_180
+332	val_332
+176	val_176
+216	val_216
+176	val_176
+192	val_192
+356	val_356
+208	val_208
+280	val_280
+4	val_4
+72	val_72
+92	val_92
+20	val_20
+316	val_316
+128	val_128
+0	val_0
+396	val_396
+208	val_208
+292	val_292
+252	val_252
 152	val_152
-348	val_348
-400	val_400
-200	val_200
+128	val_128
+224	val_224
+484	val_484
+244	val_245
+300	val_301
+76	val_77
+152	val_153
+468	val_469
+308	val_309
+100	val_101
+440	val_441
+196	val_197
+276	val_277
+244	val_245
+248	val_249
+228	val_229
+156	val_157
+100	val_101
+40	val_41
+412	val_413
+292	val_293
+256	val_257
+152	val_153
+52	val_53
+292	val_293
+348	val_349
+152	val_153
+408	val_409
+144	val_145
+496	val_497
+432	val_433
+136	val_137
+164	val_165
+284	val_285
+244	val_245
+172	val_173
+156	val_157
+436	val_437
+104	val_105
+392	val_393
+268	val_269
+0	val_1
+300	val_301
+404	val_405
+52	val_53
+60	val_61
+384	val_385
+12	val_13
+196	val_197
+216	val_217
+204	val_205
+16	val_17
+412	val_413
+76	val_77
+160	val_161
+52	val_53
+352	val_353
+356	val_357
+192	val_193
+132	val_133
+32	val_33
+104	val_105
+116	val_117
+76	val_77
+384	val_385
+404	val_405
+328	val_329
+260	val_261
+404	val_405
+324	val_325
+384	val_385
+168	val_169
+8	val_9
+40	val_41
+52	val_53
+20	val_21
+364	val_365
+416	val_417
+308	val_309
+212	val_213
+140	val_141
+80	val_81
+104	val_105
+164	val_165
+260	val_261
+484	val_485
+340	val_341
+336	val_337
+48	val_49
+264	val_265
+252	val_253
+476	val_477
+392	val_393
+480	val_481
+480	val_481
+328	val_329
+352	val_353
+284	val_285
+184	val_185
+388	val_389
+132	val_133
+120	val_121
+376	val_377
+492	val_493
+16	val_17
+68	val_69
+360	val_361
+492	val_493
+20	val_21
+196	val_197
+264	val_265
+304	val_305
+56	val_57
+4	val_5
+344	val_345
+224	val_225
+468	val_469
+128	val_129
+488	val_489
+424	val_425
+48	val_49
+476	val_477
+408	val_409
+240	val_241
+0	val_1
+128	val_129
 PREHOOK: query: EXPLAIN EXTENDED SELECT s.* FROM srcbucket TABLESAMPLE (BUCKET 4 OUT OF 4 on key) s
 ORDER BY key, value
 PREHOOK: type: QUERY
@@ -648,7 +648,7 @@ STAGE PLANS:
       Path -> Partition:
 #### A masked pattern was here ####
           Partition
-            base file name: srcbucket1.txt
+            base file name: 000001_0
             input format: org.apache.hadoop.mapred.TextInputFormat
             output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
             properties:
@@ -693,7 +693,7 @@ STAGE PLANS:
               name: default.srcbucket
             name: default.srcbucket
       Truncated Path -> Alias:
-        /srcbucket/srcbucket1.txt [s]
+        /srcbucket/000001_0 [s]
       Needs Tagging: false
       Reduce Operator Tree:
         Select Operator
@@ -1017,7 +1017,7 @@ STAGE PLANS:
       Path -> Partition:
 #### A masked pattern was here ####
           Partition
-            base file name: srcbucket0.txt
+            base file name: 000000_0
             input format: org.apache.hadoop.mapred.TextInputFormat
             output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
             properties:
@@ -1062,7 +1062,7 @@ STAGE PLANS:
               name: default.srcbucket
             name: default.srcbucket
       Truncated Path -> Alias:
-        /srcbucket/srcbucket0.txt [s]
+        /srcbucket/000000_0 [s]
       Needs Tagging: false
       Reduce Operator Tree:
         Select Operator
@@ -2556,7 +2556,7 @@ STAGE PLANS:
       Path -> Partition:
 #### A masked pattern was here ####
           Partition
-            base file name: srcbucket20.txt
+            base file name: 000000_0
             input format: org.apache.hadoop.mapred.TextInputFormat
             output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
             properties:
@@ -2602,7 +2602,7 @@ STAGE PLANS:
             name: default.srcbucket2
 #### A masked pattern was here ####
           Partition
-            base file name: srcbucket22.txt
+            base file name: 000002_0
             input format: org.apache.hadoop.mapred.TextInputFormat
             output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
             properties:
@@ -2647,8 +2647,8 @@ STAGE PLANS:
               name: default.srcbucket2
             name: default.srcbucket2
       Truncated Path -> Alias:
-        /srcbucket2/srcbucket20.txt [s]
-        /srcbucket2/srcbucket22.txt [s]
+        /srcbucket2/000000_0 [s]
+        /srcbucket2/000002_0 [s]
       Needs Tagging: false
       Reduce Operator Tree:
         Select Operator
@@ -2700,26 +2700,62 @@ POSTHOOK: Input: default@srcbucket2
 2	val_2
 4	val_4
 8	val_8
+10	val_10
+12	val_12
+12	val_12
+18	val_18
+18	val_18
 20	val_20
 24	val_24
 24	val_24
 26	val_26
 26	val_26
 28	val_28
+30	val_30
+34	val_34
 42	val_42
 42	val_42
 44	val_44
+54	val_54
+58	val_58
+58	val_58
 64	val_64
 66	val_66
+70	val_70
+70	val_70
+70	val_70
+72	val_72
+72	val_72
+74	val_74
+76	val_76
+76	val_76
+78	val_78
 80	val_80
 82	val_82
 84	val_84
 84	val_84
 86	val_86
+90	val_90
+90	val_90
+90	val_90
+92	val_92
+96	val_96
+98	val_98
+98	val_98
+100	val_100
+100	val_100
+104	val_104
+104	val_104
 114	val_114
 116	val_116
 118	val_118
 118	val_118
+120	val_120
+120	val_120
+126	val_126
+128	val_128
+128	val_128
+128	val_128
 134	val_134
 134	val_134
 136	val_136
@@ -2727,11 +2763,19 @@ POSTHOOK: Input: default@srcbucket2
 138	val_138
 138	val_138
 138	val_138
+146	val_146
+146	val_146
 150	val_150
 152	val_152
 152	val_152
 156	val_156
 158	val_158
+160	val_160
+162	val_162
+164	val_164
+164	val_164
+166	val_166
+168	val_168
 170	val_170
 172	val_172
 172	val_172
@@ -2740,6 +2784,8 @@ POSTHOOK: Input: default@srcbucket2
 176	val_176
 176	val_176
 178	val_178
+180	val_180
+186	val_186
 190	val_190
 192	val_192
 194	val_194
@@ -2750,18 +2796,38 @@ POSTHOOK: Input: default@srcbucket2
 208	val_208
 208	val_208
 208	val_208
+214	val_214
+216	val_216
+216	val_216
+218	val_218
 222	val_222
 224	val_224
 224	val_224
 226	val_226
 228	val_228
+230	val_230
+230	val_230
+230	val_230
+230	val_230
+230	val_230
+238	val_238
+238	val_238
 242	val_242
 242	val_242
 244	val_244
 248	val_248
+252	val_252
+256	val_256
+256	val_256
+258	val_258
 260	val_260
 262	val_262
 266	val_266
+272	val_272
+272	val_272
+274	val_274
+278	val_278
+278	val_278
 280	val_280
 280	val_280
 282	val_282
@@ -2770,6 +2836,14 @@ POSTHOOK: Input: default@srcbucket2
 286	val_286
 288	val_288
 288	val_288
+292	val_292
+296	val_296
+298	val_298
+298	val_298
+298	val_298
+302	val_302
+306	val_306
+308	val_308
 310	val_310
 316	val_316
 316	val_316
@@ -2777,12 +2851,34 @@ POSTHOOK: Input: default@srcbucket2
 318	val_318
 318	val_318
 318	val_318
+322	val_322
+322	val_322
 332	val_332
 336	val_336
 338	val_338
+342	val_342
+342	val_342
+344	val_344
+344	val_344
+348	val_348
+348	val_348
+348	val_348
+348	val_348
+348	val_348
 356	val_356
+360	val_360
+362	val_362
+364	val_364
+366	val_366
+368	val_368
 374	val_374
 378	val_378
+382	val_382
+382	val_382
+384	val_384
+384	val_384
+384	val_384
+386	val_386
 392	val_392
 394	val_394
 396	val_396
@@ -2796,11 +2892,28 @@ POSTHOOK: Input: default@srcbucket2
 406	val_406
 406	val_406
 406	val_406
+414	val_414
+414	val_414
+418	val_418
 424	val_424
 424	val_424
+430	val_430
+430	val_430
+430	val_430
+432	val_432
+436	val_436
+438	val_438
+438	val_438
+438	val_438
 444	val_444
 446	val_446
 448	val_448
+452	val_452
+454	val_454
+454	val_454
+454	val_454
+458	val_458
+458	val_458
 460	val_460
 462	val_462
 462	val_462
@@ -2811,11 +2924,23 @@ POSTHOOK: Input: default@srcbucket2
 468	val_468
 468	val_468
 468	val_468
+470	val_470
+472	val_472
+478	val_478
+478	val_478
 480	val_480
 480	val_480
 480	val_480
 482	val_482
 484	val_484
+490	val_490
+492	val_492
+492	val_492
+494	val_494
+496	val_496
+498	val_498
+498	val_498
+498	val_498
 PREHOOK: query: EXPLAIN EXTENDED SELECT s.* FROM srcbucket2 TABLESAMPLE (BUCKET 2 OUT OF 4 on key) s
 ORDER BY key, value
 PREHOOK: type: QUERY
@@ -2855,7 +2980,7 @@ STAGE PLANS:
       Path -> Partition:
 #### A masked pattern was here ####
           Partition
-            base file name: srcbucket21.txt
+            base file name: 000001_0
             input format: org.apache.hadoop.mapred.TextInputFormat
             output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
             properties:
@@ -2900,7 +3025,7 @@ STAGE PLANS:
               name: default.srcbucket2
             name: default.srcbucket2
       Truncated Path -> Alias:
-        /srcbucket2/srcbucket21.txt [s]
+        /srcbucket2/000001_0 [s]
       Needs Tagging: false
       Reduce Operator Tree:
         Select Operator
@@ -2950,22 +3075,103 @@ POSTHOOK: Input: default@srcbucket2
 5	val_5
 5	val_5
 9	val_9
+17	val_17
+33	val_33
+37	val_37
+37	val_37
 41	val_41
+53	val_53
+57	val_57
+65	val_65
+69	val_69
+77	val_77
 85	val_85
+97	val_97
+97	val_97
+105	val_105
+113	val_113
+113	val_113
+125	val_125
+125	val_125
+129	val_129
+129	val_129
 133	val_133
 137	val_137
 137	val_137
+145	val_145
+149	val_149
+149	val_149
+153	val_153
+157	val_157
+165	val_165
+165	val_165
+169	val_169
+169	val_169
+169	val_169
+169	val_169
 177	val_177
+181	val_181
+189	val_189
+193	val_193
+193	val_193
+193	val_193
+197	val_197
+197	val_197
+201	val_201
+205	val_205
+205	val_205
+209	val_209
+209	val_209
+213	val_213
+213	val_213
+217	val_217
+217	val_217
 221	val_221
 221	val_221
 229	val_229
 229	val_229
+233	val_233
+233	val_233
+237	val_237
+237	val_237
+241	val_241
+249	val_249
+257	val_257
 265	val_265
 265	val_265
+273	val_273
+273	val_273
+273	val_273
+277	val_277
+277	val_277
+277	val_277
+277	val_277
+281	val_281
+281	val_281
+285	val_285
+289	val_289
+305	val_305
+309	val_309
+309	val_309
 317	val_317
 317	val_317
+321	val_321
+321	val_321
+325	val_325
+325	val_325
+333	val_333
+333	val_333
+341	val_341
+345	val_345
 353	val_353
 353	val_353
+365	val_365
+369	val_369
+369	val_369
+369	val_369
+373	val_373
+377	val_377
+389	val_389
 393	val_393
 397	val_397
 397	val_397
@@ -2977,13 +3183,32 @@ POSTHOOK: Input: default@srcbucket2
 409	val_409
 409	val_409
 409	val_409
+413	val_413
+413	val_413
+417	val_417
+417	val_417
+417	val_417
+421	val_421
+429	val_429
+429	val_429
+437	val_437
 449	val_449
+453	val_453
+457	val_457
+469	val_469
+469	val_469
+469	val_469
+469	val_469
+469	val_469
+477	val_477
 481	val_481
 485	val_485
 489	val_489
 489	val_489
 489	val_489
 489	val_489
+493	val_493
+497	val_497
 PREHOOK: query: CREATE TABLE empty_bucket (key int, value string) CLUSTERED BY (key) INTO 2 BUCKETS STORED AS TEXTFILE
 PREHOOK: type: CREATETABLE
 PREHOOK: Output: database:default

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/results/clientpositive/sample7.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/sample7.q.out b/ql/src/test/results/clientpositive/sample7.q.out
index 51a45dd..1d0f0e8 100644
--- a/ql/src/test/results/clientpositive/sample7.q.out
+++ b/ql/src/test/results/clientpositive/sample7.q.out
@@ -80,7 +80,7 @@ STAGE PLANS:
       Path -> Partition:
 #### A masked pattern was here ####
           Partition
-            base file name: srcbucket0.txt
+            base file name: 000000_0
             input format: org.apache.hadoop.mapred.TextInputFormat
             output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
             properties:
@@ -125,7 +125,7 @@ STAGE PLANS:
               name: default.srcbucket
             name: default.srcbucket
       Truncated Path -> Alias:
-        /srcbucket/srcbucket0.txt [s]
+        /srcbucket/000000_0 [s]
 
   Stage: Stage-7
     Conditional Operator
@@ -363,201 +363,201 @@ POSTHOOK: query: SELECT dest1.* FROM dest1
 POSTHOOK: type: QUERY
 POSTHOOK: Input: default@dest1
 #### A masked pattern was here ####
-468	val_469
-272	val_273
-448	val_449
-440	val_441
-296	val_297
-428	val_429
-356	val_357
-128	val_129
-240	val_241
-408	val_409
-476	val_477
-424	val_425
-488	val_489
-128	val_129
-468	val_469
-224	val_225
-344	val_345
-304	val_305
-264	val_265
-196	val_197
-492	val_493
-360	val_361
-492	val_493
-376	val_377
-120	val_121
-132	val_133
-388	val_389
-184	val_185
-284	val_285
-352	val_353
-328	val_329
-480	val_481
-480	val_481
-392	val_393
-476	val_477
-252	val_253
-264	val_265
-336	val_337
-340	val_341
-484	val_485
-260	val_261
-164	val_165
-104	val_105
-140	val_141
-212	val_213
-308	val_309
-416	val_417
-364	val_365
-168	val_169
-384	val_385
-324	val_325
-404	val_405
-260	val_261
-328	val_329
-404	val_405
-384	val_385
-116	val_117
-104	val_105
-132	val_133
-192	val_193
 356	val_357
-352	val_353
-160	val_161
-412	val_413
-204	val_205
-216	val_217
-196	val_197
-384	val_385
-404	val_405
-300	val_301
-268	val_269
-392	val_393
-104	val_105
-436	val_437
-156	val_157
-172	val_173
-244	val_245
-284	val_285
-164	val_165
-136	val_137
-432	val_433
-496	val_497
-144	val_145
-408	val_409
-152	val_153
-348	val_349
-292	val_293
-152	val_153
-256	val_257
-292	val_293
-412	val_413
-156	val_157
-228	val_229
-248	val_249
-244	val_245
-276	val_277
-196	val_197
+428	val_429
+296	val_297
 440	val_441
-308	val_309
+448	val_449
+272	val_273
 468	val_469
-152	val_153
-300	val_301
-244	val_245
-484	val_484
-224	val_224
-128	val_128
-152	val_152
-252	val_252
-292	val_292
-208	val_208
-396	val_396
-128	val_128
-316	val_316
-280	val_280
-208	val_208
-356	val_356
-192	val_192
-176	val_176
-216	val_216
-176	val_176
-332	val_332
-180	val_180
-284	val_284
-260	val_260
-404	val_404
-384	val_384
-272	val_272
+200	val_200
+400	val_400
 348	val_348
-208	val_208
+152	val_152
+448	val_448
+344	val_344
 348	val_348
-172	val_172
-496	val_496
-468	val_468
-120	val_120
-404	val_404
-436	val_436
-156	val_156
-468	val_468
-308	val_308
-196	val_196
-288	val_288
-316	val_316
-364	val_364
-224	val_224
-392	val_392
-272	val_272
-452	val_452
-396	val_396
-336	val_336
-168	val_168
-472	val_472
-160	val_160
 492	val_492
-228	val_228
-468	val_468
-368	val_368
-296	val_296
-216	val_216
-344	val_344
-116	val_116
+384	val_384
 256	val_256
+384	val_384
+172	val_172
+136	val_136
 480	val_480
-288	val_288
-244	val_244
-128	val_128
-432	val_432
-316	val_316
-280	val_280
+460	val_460
+468	val_468
+120	val_120
+444	val_444
+248	val_248
+360	val_360
+200	val_200
 104	val_104
-348	val_348
+480	val_480
 424	val_424
-396	val_396
 164	val_164
 164	val_164
+396	val_396
 424	val_424
-480	val_480
+348	val_348
 104	val_104
-200	val_200
-360	val_360
-248	val_248
-444	val_444
-120	val_120
-468	val_468
-460	val_460
+280	val_280
+316	val_316
+432	val_432
+128	val_128
+244	val_244
+288	val_288
 480	val_480
-136	val_136
-172	val_172
-384	val_384
 256	val_256
-384	val_384
+116	val_116
+344	val_344
+216	val_216
+296	val_296
+368	val_368
+468	val_468
+228	val_228
 492	val_492
+160	val_160
+472	val_472
+168	val_168
+336	val_336
+396	val_396
+452	val_452
+272	val_272
+392	val_392
+224	val_224
+364	val_364
+316	val_316
+288	val_288
+196	val_196
+308	val_308
+468	val_468
+156	val_156
+436	val_436
+404	val_404
+120	val_120
+468	val_468
+496	val_496
+172	val_172
 348	val_348
-344	val_344
-448	val_448
-152	val_152
+208	val_208
 348	val_348
-400	val_400
-200	val_200
+272	val_272
+384	val_384
+404	val_404
+260	val_260
+284	val_284
+180	val_180
+332	val_332
+176	val_176
+216	val_216
+176	val_176
+192	val_192
+356	val_356
+208	val_208
+280	val_280
+316	val_316
+128	val_128
+396	val_396
+208	val_208
+292	val_292
+252	val_252
+152	val_152
+128	val_128
+224	val_224
+484	val_484
+244	val_245
+300	val_301
+152	val_153
+468	val_469
+308	val_309
+440	val_441
+196	val_197
+276	val_277
+244	val_245
+248	val_249
+228	val_229
+156	val_157
+412	val_413
+292	val_293
+256	val_257
+152	val_153
+292	val_293
+348	val_349
+152	val_153
+408	val_409
+144	val_145
+496	val_497
+432	val_433
+136	val_137
+164	val_165
+284	val_285
+244	val_245
+172	val_173
+156	val_157
+436	val_437
+104	val_105
+392	val_393
+268	val_269
+300	val_301
+404	val_405
+384	val_385
+196	val_197
+216	val_217
+204	val_205
+412	val_413
+160	val_161
+352	val_353
+356	val_357
+192	val_193
+132	val_133
+104	val_105
+116	val_117
+384	val_385
+404	val_405
+328	val_329
+260	val_261
+404	val_405
+324	val_325
+384	val_385
+168	val_169
+364	val_365
+416	val_417
+308	val_309
+212	val_213
+140	val_141
+104	val_105
+164	val_165
+260	val_261
+484	val_485
+340	val_341
+336	val_337
+264	val_265
+252	val_253
+476	val_477
+392	val_393
+480	val_481
+480	val_481
+328	val_329
+352	val_353
+284	val_285
+184	val_185
+388	val_389
+132	val_133
+120	val_121
+376	val_377
+492	val_493
+360	val_361
+492	val_493
+196	val_197
+264	val_265
+304	val_305
+344	val_345
+224	val_225
+468	val_469
+128	val_129
+488	val_489
+424	val_425
+476	val_477
+408	val_409
+240	val_241
+128	val_129

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/results/clientpositive/sample9.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/sample9.q.out b/ql/src/test/results/clientpositive/sample9.q.out
index a4c3ff6..f4afad4 100644
--- a/ql/src/test/results/clientpositive/sample9.q.out
+++ b/ql/src/test/results/clientpositive/sample9.q.out
@@ -54,7 +54,7 @@ STAGE PLANS:
       Path -> Partition:
 #### A masked pattern was here ####
           Partition
-            base file name: srcbucket0.txt
+            base file name: 000000_0
             input format: org.apache.hadoop.mapred.TextInputFormat
             output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
             properties:
@@ -99,7 +99,7 @@ STAGE PLANS:
               name: default.srcbucket
             name: default.srcbucket
       Truncated Path -> Alias:
-        /srcbucket/srcbucket0.txt [s:a]
+        /srcbucket/000000_0 [s:a]
 
   Stage: Stage-0
     Fetch Operator
@@ -117,496 +117,496 @@ FROM (SELECT a.* FROM srcbucket TABLESAMPLE (BUCKET 1 OUT OF 2 on key) a) s
 POSTHOOK: type: QUERY
 POSTHOOK: Input: default@srcbucket
 #### A masked pattern was here ####
-474	val_475
-62	val_63
-468	val_469
-272	val_273
-448	val_449
-246	val_247
-440	val_441
-278	val_279
-296	val_297
-428	val_429
-126	val_127
-106	val_107
-356	val_357
 490	val_491
-402	val_403
-128	val_129
-10	val_11
-226	val_227
-110	val_111
-0	val_1
-240	val_241
-286	val_287
-408	val_409
-476	val_477
-482	val_483
-48	val_49
-424	val_425
-226	val_227
-494	val_495
-488	val_489
-94	val_95
-50	val_51
-402	val_403
-128	val_129
-468	val_469
-314	val_315
-224	val_225
-344	val_345
-4	val_5
-206	val_207
-114	val_115
-56	val_57
-114	val_115
-254	val_255
-390	val_391
-304	val_305
-264	val_265
-196	val_197
-238	val_239
-20	val_21
-492	val_493
-82	val_83
-58	val_59
-86	val_87
-438	val_439
-360	val_361
-222	val_223
-42	val_43
-338	val_339
-68	val_69
-16	val_17
-492	val_493
-376	val_377
-120	val_121
-306	val_307
-426	val_427
-132	val_133
-446	val_447
-386	val_387
-388	val_389
-184	val_185
-284	val_285
-246	val_247
-262	val_263
-122	val_123
-438	val_439
-390	val_391
-352	val_353
-226	val_227
-328	val_329
-382	val_383
-342	val_343
-480	val_481
-102	val_103
-480	val_481
-318	val_319
-392	val_393
-476	val_477
-258	val_259
-174	val_175
-252	val_253
-114	val_115
-264	val_265
-48	val_49
-336	val_337
-340	val_341
-390	val_391
-484	val_485
-6	val_7
-260	val_261
-2	val_3
-170	val_171
-164	val_165
-118	val_119
-310	val_311
-104	val_105
-80	val_81
-326	val_327
-450	val_451
-140	val_141
-212	val_213
-308	val_309
-30	val_31
-358	val_359
-416	val_417
-42	val_43
-386	val_387
-454	val_455
-364	val_365
-20	val_21
-52	val_53
-40	val_41
-8	val_9
-168	val_169
-384	val_385
-324	val_325
-310	val_311
-206	val_207
-404	val_405
-206	val_207
-226	val_227
-262	val_263
-260	val_261
-328	val_329
-322	val_323
-122	val_123
-404	val_405
-384	val_385
-76	val_77
-116	val_117
-42	val_43
-104	val_105
-406	val_407
-32	val_33
-132	val_133
-192	val_193
-58	val_59
-70	val_71
 356	val_357
-352	val_353
-52	val_53
-330	val_331
-138	val_139
-160	val_161
-454	val_455
-76	val_77
-174	val_175
-412	val_413
-16	val_17
-204	val_205
+106	val_107
 126	val_127
-274	val_275
-374	val_375
-494	val_495
-216	val_217
-470	val_471
-196	val_197
-302	val_303
-450	val_451
-12	val_13
-398	val_399
-334	val_335
-384	val_385
-60	val_61
-442	val_443
-52	val_53
-404	val_405
-446	val_447
-300	val_301
-0	val_1
-268	val_269
-392	val_393
-104	val_105
-436	val_437
-156	val_157
-118	val_119
-172	val_173
-244	val_245
-6	val_7
-284	val_285
-164	val_165
-136	val_137
-462	val_463
-432	val_433
-496	val_497
-144	val_145
-408	val_409
-152	val_153
-382	val_383
-348	val_349
-122	val_123
-292	val_293
-182	val_183
-474	val_475
-310	val_311
-52	val_53
-486	val_487
-152	val_153
-378	val_379
-414	val_415
-256	val_257
-292	val_293
-412	val_413
-40	val_41
-478	val_479
-178	val_179
-100	val_101
-156	val_157
-228	val_229
-22	val_23
-248	val_249
-402	val_403
-62	val_63
-162	val_163
-244	val_245
-276	val_277
-46	val_47
-78	val_79
-134	val_135
-196	val_197
-410	val_411
-82	val_83
+428	val_429
+296	val_297
+278	val_279
 440	val_441
-100	val_101
-308	val_309
-430	val_431
+246	val_247
+448	val_449
+272	val_273
 468	val_469
-152	val_153
-138	val_139
-76	val_77
-300	val_301
-478	val_479
-118	val_119
-178	val_179
-242	val_243
-244	val_245
-238	val_238
-86	val_86
-278	val_278
-98	val_98
-484	val_484
-150	val_150
-224	val_224
-66	val_66
-128	val_128
-146	val_146
-406	val_406
-374	val_374
+62	val_63
+474	val_475
+200	val_200
+400	val_400
+90	val_90
+126	val_126
+222	val_222
+414	val_414
+194	val_194
+348	val_348
 152	val_152
-82	val_82
-166	val_166
-430	val_430
-252	val_252
-292	val_292
-338	val_338
-446	val_446
-394	val_394
-482	val_482
-174	val_174
-494	val_494
-466	val_466
-208	val_208
-174	val_174
-396	val_396
-162	val_162
-266	val_266
-342	val_342
-0	val_0
-128	val_128
-316	val_316
-302	val_302
-438	val_438
-170	val_170
-20	val_20
-378	val_378
-92	val_92
-72	val_72
-4	val_4
-280	val_280
-208	val_208
-356	val_356
-382	val_382
-498	val_498
-386	val_386
-192	val_192
-286	val_286
-176	val_176
-54	val_54
-138	val_138
-216	val_216
-430	val_430
-278	val_278
-176	val_176
-318	val_318
-332	val_332
-180	val_180
-284	val_284
-12	val_12
-230	val_230
-260	val_260
-404	val_404
-384	val_384
-272	val_272
-138	val_138
+448	val_448
+28	val_28
 84	val_84
+344	val_344
+18	val_18
 348	val_348
-466	val_466
-58	val_58
-8	val_8
-230	val_230
-208	val_208
-348	val_348
-24	val_24
-172	val_172
-42	val_42
-158	val_158
-496	val_496
-0	val_0
-322	val_322
-468	val_468
-454	val_454
-100	val_100
-298	val_298
-418	val_418
-96	val_96
-26	val_26
-230	val_230
-120	val_120
-404	val_404
-436	val_436
-156	val_156
-468	val_468
-308	val_308
-196	val_196
-288	val_288
-98	val_98
-282	val_282
-318	val_318
-318	val_318
-470	val_470
-316	val_316
-0	val_0
-490	val_490
-364	val_364
-118	val_118
-134	val_134
-282	val_282
-138	val_138
-238	val_238
-118	val_118
-72	val_72
-90	val_90
-10	val_10
-306	val_306
-224	val_224
-242	val_242
-392	val_392
-272	val_272
-242	val_242
-452	val_452
-226	val_226
-402	val_402
-396	val_396
-58	val_58
-336	val_336
-168	val_168
-34	val_34
-472	val_472
-322	val_322
-498	val_498
-160	val_160
-42	val_42
-430	val_430
+186	val_186
+362	val_362
 458	val_458
-78	val_78
-76	val_76
+146	val_146
+498	val_498
+298	val_298
+100	val_100
 492	val_492
-218	val_218
-228	val_228
-138	val_138
-30	val_30
-64	val_64
-468	val_468
-76	val_76
-74	val_74
-342	val_342
-230	val_230
-368	val_368
-296	val_296
-216	val_216
-344	val_344
-274	val_274
-116	val_116
+462	val_462
+18	val_18
+384	val_384
+134	val_134
+26	val_26
 256	val_256
-70	val_70
+384	val_384
+454	val_454
+406	val_406
+462	val_462
+214	val_214
+172	val_172
+136	val_136
 480	val_480
-288	val_288
-244	val_244
+460	val_460
+310	val_310
+468	val_468
+178	val_178
+478	val_478
+230	val_230
+120	val_120
+444	val_444
+248	val_248
+360	val_360
+200	val_200
+414	val_414
 438	val_438
-128	val_128
-432	val_432
-202	val_202
-316	val_316
-280	val_280
-2	val_2
-80	val_80
-44	val_44
+70	val_70
 104	val_104
-466	val_466
-366	val_366
-406	val_406
-190	val_190
-406	val_406
-114	val_114
-258	val_258
-90	val_90
-262	val_262
-348	val_348
+24	val_24
+480	val_480
+70	val_70
+382	val_382
 424	val_424
-12	val_12
-396	val_396
 164	val_164
-454	val_454
-478	val_478
 298	val_298
+478	val_478
+454	val_454
 164	val_164
+396	val_396
+12	val_12
 424	val_424
-382	val_382
-70	val_70
-480	val_480
-24	val_24
+348	val_348
+262	val_262
+90	val_90
+258	val_258
+114	val_114
+406	val_406
+190	val_190
+406	val_406
+366	val_366
+466	val_466
 104	val_104
-70	val_70
+44	val_44
+80	val_80
+2	val_2
+280	val_280
+316	val_316
+202	val_202
+432	val_432
+128	val_128
 438	val_438
-414	val_414
-200	val_200
-360	val_360
-248	val_248
-444	val_444
-120	val_120
-230	val_230
-478	val_478
-178	val_178
-468	val_468
-310	val_310
-460	val_460
+244	val_244
+288	val_288
 480	val_480
-136	val_136
-172	val_172
-214	val_214
-462	val_462
-406	val_406
-454	val_454
-384	val_384
+70	val_70
 256	val_256
-26	val_26
-134	val_134
-384	val_384
-18	val_18
-462	val_462
+116	val_116
+274	val_274
+344	val_344
+216	val_216
+296	val_296
+368	val_368
+230	val_230
+342	val_342
+74	val_74
+76	val_76
+468	val_468
+64	val_64
+30	val_30
+138	val_138
+228	val_228
+218	val_218
 492	val_492
-100	val_100
-298	val_298
-498	val_498
-146	val_146
+76	val_76
+78	val_78
 458	val_458
-362	val_362
-186	val_186
+430	val_430
+42	val_42
+160	val_160
+498	val_498
+322	val_322
+472	val_472
+34	val_34
+168	val_168
+336	val_336
+58	val_58
+396	val_396
+402	val_402
+226	val_226
+452	val_452
+242	val_242
+272	val_272
+392	val_392
+242	val_242
+224	val_224
+306	val_306
+10	val_10
+90	val_90
+72	val_72
+118	val_118
+238	val_238
+138	val_138
+282	val_282
+134	val_134
+118	val_118
+364	val_364
+490	val_490
+0	val_0
+316	val_316
+470	val_470
+318	val_318
+318	val_318
+282	val_282
+98	val_98
+288	val_288
+196	val_196
+308	val_308
+468	val_468
+156	val_156
+436	val_436
+404	val_404
+120	val_120
+230	val_230
+26	val_26
+96	val_96
+418	val_418
+298	val_298
+100	val_100
+454	val_454
+468	val_468
+322	val_322
+0	val_0
+496	val_496
+158	val_158
+42	val_42
+172	val_172
+24	val_24
+348	val_348
+208	val_208
+230	val_230
+8	val_8
+58	val_58
+466	val_466
 348	val_348
-18	val_18
-344	val_344
 84	val_84
-28	val_28
-448	val_448
+138	val_138
+272	val_272
+384	val_384
+404	val_404
+260	val_260
+230	val_230
+12	val_12
+284	val_284
+180	val_180
+332	val_332
+318	val_318
+176	val_176
+278	val_278
+430	val_430
+216	val_216
+138	val_138
+54	val_54
+176	val_176
+286	val_286
+192	val_192
+386	val_386
+498	val_498
+382	val_382
+356	val_356
+208	val_208
+280	val_280
+4	val_4
+72	val_72
+92	val_92
+378	val_378
+20	val_20
+170	val_170
+438	val_438
+302	val_302
+316	val_316
+128	val_128
+0	val_0
+342	val_342
+266	val_266
+162	val_162
+396	val_396
+174	val_174
+208	val_208
+466	val_466
+494	val_494
+174	val_174
+482	val_482
+394	val_394
+446	val_446
+338	val_338
+292	val_292
+252	val_252
+430	val_430
+166	val_166
+82	val_82
 152	val_152
-348	val_348
-194	val_194
-414	val_414
-222	val_222
-126	val_126
-90	val_90
-400	val_400
-200	val_200
+374	val_374
+406	val_406
+146	val_146
+128	val_128
+66	val_66
+224	val_224
+150	val_150
+484	val_484
+98	val_98
+278	val_278
+86	val_86
+238	val_238
+244	val_245
+242	val_243
+178	val_179
+118	val_119
+478	val_479
+300	val_301
+76	val_77
+138	val_139
+152	val_153
+468	val_469
+430	val_431
+308	val_309
+100	val_101
+440	val_441
+82	val_83
+410	val_411
+196	val_197
+134	val_135
+78	val_79
+46	val_47
+276	val_277
+244	val_245
+162	val_163
+62	val_63
+402	val_403
+248	val_249
+22	val_23
+228	val_229
+156	val_157
+100	val_101
+178	val_179
+478	val_479
+40	val_41
+412	val_413
+292	val_293
+256	val_257
+414	val_415
+378	val_379
+152	val_153
+486	val_487
+52	val_53
+310	val_311
+474	val_475
+182	val_183
+292	val_293
+122	val_123
+348	val_349
+382	val_383
+152	val_153
+408	val_409
+144	val_145
+496	val_497
+432	val_433
+462	val_463
+136	val_137
+164	val_165
+284	val_285
+6	val_7
+244	val_245
+172	val_173
+118	val_119
+156	val_157
+436	val_437
+104	val_105
+392	val_393
+268	val_269
+0	val_1
+300	val_301
+446	val_447
+404	val_405
+52	val_53
+442	val_443
+60	val_61
+384	val_385
+334	val_335
+398	val_399
+12	val_13
+450	val_451
+302	val_303
+196	val_197
+470	val_471
+216	val_217
+494	val_495
+374	val_375
+274	val_275
+126	val_127
+204	val_205
+16	val_17
+412	val_413
+174	val_175
+76	val_77
+454	val_455
+160	val_161
+138	val_139
+330	val_331
+52	val_53
+352	val_353
+356	val_357
+70	val_71
+58	val_59
+192	val_193
+132	val_133
+32	val_33
+406	val_407
+104	val_105
+42	val_43
+116	val_117
+76	val_77
+384	val_385
+404	val_405
+122	val_123
+322	val_323
+328	val_329
+260	val_261
+262	val_263
+226	val_227
+206	val_207
+404	val_405
+206	val_207
+310	val_311
+324	val_325
+384	val_385
+168	val_169
+8	val_9
+40	val_41
+52	val_53
+20	val_21
+364	val_365
+454	val_455
+386	val_387
+42	val_43
+416	val_417
+358	val_359
+30	val_31
+308	val_309
+212	val_213
+140	val_141
+450	val_451
+326	val_327
+80	val_81
+104	val_105
+310	val_311
+118	val_119
+164	val_165
+170	val_171
+2	val_3
+260	val_261
+6	val_7
+484	val_485
+390	val_391
+340	val_341
+336	val_337
+48	val_49
+264	val_265
+114	val_115
+252	val_253
+174	val_175
+258	val_259
+476	val_477
+392	val_393
+318	val_319
+480	val_481
+102	val_103
+480	val_481
+342	val_343
+382	val_383
+328	val_329
+226	val_227
+352	val_353
+390	val_391
+438	val_439
+122	val_123
+262	val_263
+246	val_247
+284	val_285
+184	val_185
+388	val_389
+386	val_387
+446	val_447
+132	val_133
+426	val_427
+306	val_307
+120	val_121
+376	val_377
+492	val_493
+16	val_17
+68	val_69
+338	val_339
+42	val_43
+222	val_223
+360	val_361
+438	val_439
+86	val_87
+58	val_59
+82	val_83
+492	val_493
+20	val_21
+238	val_239
+196	val_197
+264	val_265
+304	val_305
+390	val_391
+254	val_255
+114	val_115
+56	val_57
+114	val_115
+206	val_207
+4	val_5
+344	val_345
+224	val_225
+314	val_315
+468	val_469
+128	val_129
+402	val_403
+50	val_51
+94	val_95
+488	val_489
+494	val_495
+226	val_227
+424	val_425
+48	val_49
+482	val_483
+476	val_477
+408	val_409
+286	val_287
+240	val_241
+0	val_1
+110	val_111
+226	val_227
+10	val_11
+128	val_129
+402	val_403

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/results/clientpositive/spark/sample2.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/spark/sample2.q.out b/ql/src/test/results/clientpositive/spark/sample2.q.out
index fe9e2f5..fa230aa 100644
--- a/ql/src/test/results/clientpositive/spark/sample2.q.out
+++ b/ql/src/test/results/clientpositive/spark/sample2.q.out
@@ -79,7 +79,7 @@ STAGE PLANS:
             Path -> Partition:
 #### A masked pattern was here ####
                 Partition
-                  base file name: srcbucket0.txt
+                  base file name: 000000_0
                   input format: org.apache.hadoop.mapred.TextInputFormat
                   output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
                   properties:
@@ -124,7 +124,7 @@ STAGE PLANS:
                     name: default.srcbucket
                   name: default.srcbucket
             Truncated Path -> Alias:
-              /srcbucket/srcbucket0.txt [s]
+              /srcbucket/000000_0 [s]
 
   Stage: Stage-0
     Move Operator

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/results/clientpositive/spark/sample4.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/spark/sample4.q.out b/ql/src/test/results/clientpositive/spark/sample4.q.out
index 987a445..0f2af55 100644
--- a/ql/src/test/results/clientpositive/spark/sample4.q.out
+++ b/ql/src/test/results/clientpositive/spark/sample4.q.out
@@ -79,7 +79,7 @@ STAGE PLANS:
             Path -> Partition:
 #### A masked pattern was here ####
                 Partition
-                  base file name: srcbucket0.txt
+                  base file name: 000000_0
                   input format: org.apache.hadoop.mapred.TextInputFormat
                   output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
                   properties:
@@ -124,7 +124,7 @@ STAGE PLANS:
                     name: default.srcbucket
                   name: default.srcbucket
             Truncated Path -> Alias:
-              /srcbucket/srcbucket0.txt [s]
+              /srcbucket/000000_0 [s]
 
   Stage: Stage-0
     Move Operator

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/results/clientpositive/spark/sample6.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/spark/sample6.q.out b/ql/src/test/results/clientpositive/spark/sample6.q.out
index 2ed7d7a..1158732 100644
--- a/ql/src/test/results/clientpositive/spark/sample6.q.out
+++ b/ql/src/test/results/clientpositive/spark/sample6.q.out
@@ -77,7 +77,7 @@ STAGE PLANS:
             Path -> Partition:
 #### A masked pattern was here ####
                 Partition
-                  base file name: srcbucket0.txt
+                  base file name: 000000_0
                   input format: org.apache.hadoop.mapred.TextInputFormat
                   output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
                   properties:
@@ -122,7 +122,7 @@ STAGE PLANS:
                     name: default.srcbucket
                   name: default.srcbucket
             Truncated Path -> Alias:
-              /srcbucket/srcbucket0.txt [s]
+              /srcbucket/000000_0 [s]
 
   Stage: Stage-0
     Move Operator
@@ -468,7 +468,7 @@ STAGE PLANS:
             Path -> Partition:
 #### A masked pattern was here ####
                 Partition
-                  base file name: srcbucket1.txt
+                  base file name: 000001_0
                   input format: org.apache.hadoop.mapred.TextInputFormat
                   output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
                   properties:
@@ -513,7 +513,7 @@ STAGE PLANS:
                     name: default.srcbucket
                   name: default.srcbucket
             Truncated Path -> Alias:
-              /srcbucket/srcbucket1.txt [s]
+              /srcbucket/000001_0 [s]
         Reducer 2 
             Needs Tagging: false
             Reduce Operator Tree:
@@ -843,7 +843,7 @@ STAGE PLANS:
             Path -> Partition:
 #### A masked pattern was here ####
                 Partition
-                  base file name: srcbucket0.txt
+                  base file name: 000000_0
                   input format: org.apache.hadoop.mapred.TextInputFormat
                   output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
                   properties:
@@ -888,7 +888,7 @@ STAGE PLANS:
                     name: default.srcbucket
                   name: default.srcbucket
             Truncated Path -> Alias:
-              /srcbucket/srcbucket0.txt [s]
+              /srcbucket/000000_0 [s]
         Reducer 2 
             Needs Tagging: false
             Reduce Operator Tree:
@@ -2400,7 +2400,7 @@ STAGE PLANS:
             Path -> Partition:
 #### A masked pattern was here ####
                 Partition
-                  base file name: srcbucket20.txt
+                  base file name: 000000_0
                   input format: org.apache.hadoop.mapred.TextInputFormat
                   output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
                   properties:
@@ -2446,7 +2446,7 @@ STAGE PLANS:
                   name: default.srcbucket2
 #### A masked pattern was here ####
                 Partition
-                  base file name: srcbucket22.txt
+                  base file name: 000002_0
                   input format: org.apache.hadoop.mapred.TextInputFormat
                   output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
                   properties:
@@ -2491,8 +2491,8 @@ STAGE PLANS:
                     name: default.srcbucket2
                   name: default.srcbucket2
             Truncated Path -> Alias:
-              /srcbucket2/srcbucket20.txt [s]
-              /srcbucket2/srcbucket22.txt [s]
+              /srcbucket2/000000_0 [s]
+              /srcbucket2/000002_0 [s]
         Reducer 2 
             Needs Tagging: false
             Reduce Operator Tree:
@@ -2545,26 +2545,62 @@ POSTHOOK: Input: default@srcbucket2
 2	val_2
 4	val_4
 8	val_8
+10	val_10
+12	val_12
+12	val_12
+18	val_18
+18	val_18
 20	val_20
 24	val_24
 24	val_24
 26	val_26
 26	val_26
 28	val_28
+30	val_30
+34	val_34
 42	val_42
 42	val_42
 44	val_44
+54	val_54
+58	val_58
+58	val_58
 64	val_64
 66	val_66
+70	val_70
+70	val_70
+70	val_70
+72	val_72
+72	val_72
+74	val_74
+76	val_76
+76	val_76
+78	val_78
 80	val_80
 82	val_82
 84	val_84
 84	val_84
 86	val_86
+90	val_90
+90	val_90
+90	val_90
+92	val_92
+96	val_96
+98	val_98
+98	val_98
+100	val_100
+100	val_100
+104	val_104
+104	val_104
 114	val_114
 116	val_116
 118	val_118
 118	val_118
+120	val_120
+120	val_120
+126	val_126
+128	val_128
+128	val_128
+128	val_128
 134	val_134
 134	val_134
 136	val_136
@@ -2572,11 +2608,19 @@ POSTHOOK: Input: default@srcbucket2
 138	val_138
 138	val_138
 138	val_138
+146	val_146
+146	val_146
 150	val_150
 152	val_152
 152	val_152
 156	val_156
 158	val_158
+160	val_160
+162	val_162
+164	val_164
+164	val_164
+166	val_166
+168	val_168
 170	val_170
 172	val_172
 172	val_172
@@ -2585,6 +2629,8 @@ POSTHOOK: Input: default@srcbucket2
 176	val_176
 176	val_176
 178	val_178
+180	val_180
+186	val_186
 190	val_190
 192	val_192
 194	val_194
@@ -2595,18 +2641,38 @@ POSTHOOK: Input: default@srcbucket2
 208	val_208
 208	val_208
 208	val_208
+214	val_214
+216	val_216
+216	val_216
+218	val_218
 222	val_222
 224	val_224
 224	val_224
 226	val_226
 228	val_228
+230	val_230
+230	val_230
+230	val_230
+230	val_230
+230	val_230
+238	val_238
+238	val_238
 242	val_242
 242	val_242
 244	val_244
 248	val_248
+252	val_252
+256	val_256
+256	val_256
+258	val_258
 260	val_260
 262	val_262
 266	val_266
+272	val_272
+272	val_272
+274	val_274
+278	val_278
+278	val_278
 280	val_280
 280	val_280
 282	val_282
@@ -2615,6 +2681,14 @@ POSTHOOK: Input: default@srcbucket2
 286	val_286
 288	val_288
 288	val_288
+292	val_292
+296	val_296
+298	val_298
+298	val_298
+298	val_298
+302	val_302
+306	val_306
+308	val_308
 310	val_310
 316	val_316
 316	val_316
@@ -2622,12 +2696,34 @@ POSTHOOK: Input: default@srcbucket2
 318	val_318
 318	val_318
 318	val_318
+322	val_322
+322	val_322
 332	val_332
 336	val_336
 338	val_338
+342	val_342
+342	val_342
+344	val_344
+344	val_344
+348	val_348
+348	val_348
+348	val_348
+348	val_348
+348	val_348
 356	val_356
+360	val_360
+362	val_362
+364	val_364
+366	val_366
+368	val_368
 374	val_374
 378	val_378
+382	val_382
+382	val_382
+384	val_384
+384	val_384
+384	val_384
+386	val_386
 392	val_392
 394	val_394
 396	val_396
@@ -2641,11 +2737,28 @@ POSTHOOK: Input: default@srcbucket2
 406	val_406
 406	val_406
 406	val_406
+414	val_414
+414	val_414
+418	val_418
 424	val_424
 424	val_424
+430	val_430
+430	val_430
+430	val_430
+432	val_432
+436	val_436
+438	val_438
+438	val_438
+438	val_438
 444	val_444
 446	val_446
 448	val_448
+452	val_452
+454	val_454
+454	val_454
+454	val_454
+458	val_458
+458	val_458
 460	val_460
 462	val_462
 462	val_462
@@ -2656,11 +2769,23 @@ POSTHOOK: Input: default@srcbucket2
 468	val_468
 468	val_468
 468	val_468
+470	val_470
+472	val_472
+478	val_478
+478	val_478
 480	val_480
 480	val_480
 480	val_480
 482	val_482
 484	val_484
+490	val_490
+492	val_492
+492	val_492
+494	val_494
+496	val_496
+498	val_498
+498	val_498
+498	val_498
 PREHOOK: query: EXPLAIN EXTENDED SELECT s.* FROM srcbucket2 TABLESAMPLE (BUCKET 2 OUT OF 4 on key) s
 ORDER BY key, value
 PREHOOK: type: QUERY
@@ -2705,7 +2830,7 @@ STAGE PLANS:
             Path -> Partition:
 #### A masked pattern was here ####
                 Partition
-                  base file name: srcbucket21.txt
+                  base file name: 000001_0
                   input format: org.apache.hadoop.mapred.TextInputFormat
                   output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
                   properties:
@@ -2750,7 +2875,7 @@ STAGE PLANS:
                     name: default.srcbucket2
                   name: default.srcbucket2
             Truncated Path -> Alias:
-              /srcbucket2/srcbucket21.txt [s]
+              /srcbucket2/000001_0 [s]
         Reducer 2 
             Needs Tagging: false
             Reduce Operator Tree:
@@ -2801,22 +2926,103 @@ POSTHOOK: Input: default@srcbucket2
 5	val_5
 5	val_5
 9	val_9
+17	val_17
+33	val_33
+37	val_37
+37	val_37
 41	val_41
+53	val_53
+57	val_57
+65	val_65
+69	val_69
+77	val_77
 85	val_85
+97	val_97
+97	val_97
+105	val_105
+113	val_113
+113	val_113
+125	val_125
+125	val_125
+129	val_129
+129	val_129
 133	val_133
 137	val_137
 137	val_137
+145	val_145
+149	val_149
+149	val_149
+153	val_153
+157	val_157
+165	val_165
+165	val_165
+169	val_169
+169	val_169
+169	val_169
+169	val_169
 177	val_177
+181	val_181
+189	val_189
+193	val_193
+193	val_193
+193	val_193
+197	val_197
+197	val_197
+201	val_201
+205	val_205
+205	val_205
+209	val_209
+209	val_209
+213	val_213
+213	val_213
+217	val_217
+217	val_217
 221	val_221
 221	val_221
 229	val_229
 229	val_229
+233	val_233
+233	val_233
+237	val_237
+237	val_237
+241	val_241
+249	val_249
+257	val_257
 265	val_265
 265	val_265
+273	val_273
+273	val_273
+273	val_273
+277	val_277
+277	val_277
+277	val_277
+277	val_277
+281	val_281
+281	val_281
+285	val_285
+289	val_289
+305	val_305
+309	val_309
+309	val_309
 317	val_317
 317	val_317
+321	val_321
+321	val_321
+325	val_325
+325	val_325
+333	val_333
+333	val_333
+341	val_341
+345	val_345
 353	val_353
 353	val_353
+365	val_365
+369	val_369
+369	val_369
+369	val_369
+373	val_373
+377	val_377
+389	val_389
 393	val_393
 397	val_397
 397	val_397
@@ -2828,13 +3034,32 @@ POSTHOOK: Input: default@srcbucket2
 409	val_409
 409	val_409
 409	val_409
+413	val_413
+413	val_413
+417	val_417
+417	val_417
+417	val_417
+421	val_421
+429	val_429
+429	val_429
+437	val_437
 449	val_449
+453	val_453
+457	val_457
+469	val_469
+469	val_469
+469	val_469
+469	val_469
+469	val_469
+477	val_477
 481	val_481
 485	val_485
 489	val_489
 489	val_489
 489	val_489
 489	val_489
+493	val_493
+497	val_497
 PREHOOK: query: CREATE TABLE empty_bucket (key int, value string) CLUSTERED BY (key) INTO 2 BUCKETS STORED AS TEXTFILE
 PREHOOK: type: CREATETABLE
 PREHOOK: Output: database:default

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/results/clientpositive/spark/sample7.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientpositive/spark/sample7.q.out b/ql/src/test/results/clientpositive/spark/sample7.q.out
index 784000d..22663ac 100644
--- a/ql/src/test/results/clientpositive/spark/sample7.q.out
+++ b/ql/src/test/results/clientpositive/spark/sample7.q.out
@@ -78,7 +78,7 @@ STAGE PLANS:
             Path -> Partition:
 #### A masked pattern was here ####
                 Partition
-                  base file name: srcbucket0.txt
+                  base file name: 000000_0
                   input format: org.apache.hadoop.mapred.TextInputFormat
                   output format: org.apache.hadoop.hive.ql.io.HiveIgnoreKeyTextOutputFormat
                   properties:
@@ -123,7 +123,7 @@ STAGE PLANS:
                     name: default.srcbucket
                   name: default.srcbucket
             Truncated Path -> Alias:
-              /srcbucket/srcbucket0.txt [s]
+              /srcbucket/000000_0 [s]
 
   Stage: Stage-0
     Move Operator


[2/2] hive git commit: HIVE-15148 : disallow loading data into bucketed tables (by default) (Sergey Shelukhin, reviewed by Ashutosh Chauhan)

Posted by se...@apache.org.
HIVE-15148 : disallow loading data into bucketed tables (by default) (Sergey Shelukhin, reviewed by Ashutosh Chauhan)


Project: http://git-wip-us.apache.org/repos/asf/hive/repo
Commit: http://git-wip-us.apache.org/repos/asf/hive/commit/0a6fc638
Tree: http://git-wip-us.apache.org/repos/asf/hive/tree/0a6fc638
Diff: http://git-wip-us.apache.org/repos/asf/hive/diff/0a6fc638

Branch: refs/heads/master
Commit: 0a6fc63858601d30ba7b6da61663e82e300e454d
Parents: 8a1dcd7
Author: Sergey Shelukhin <se...@apache.org>
Authored: Fri Nov 18 11:14:20 2016 -0800
Committer: Sergey Shelukhin <se...@apache.org>
Committed: Fri Nov 18 11:14:20 2016 -0800

----------------------------------------------------------------------
 .../org/apache/hadoop/hive/conf/HiveConf.java   |  19 +-
 data/scripts/q_test_init.sql                    |  20 +-
 .../hive/ql/parse/LoadSemanticAnalyzer.java     |  10 +
 .../alter_concatenate_indexed_table.q           |   2 +
 .../clientnegative/alter_view_failure6.q        |   2 +
 .../clientnegative/bucket_mapjoin_mismatch1.q   |   2 +
 .../bucket_mapjoin_wrong_table_metadata_1.q     |   2 +
 .../bucket_mapjoin_wrong_table_metadata_2.q     |   2 +
 .../clientnegative/compare_double_bigint.q      |   2 +
 .../clientnegative/compare_string_bigint.q      |   2 +
 .../dynamic_partitions_with_whitelist.q         |   2 +
 .../exim_11_nonpart_noncompat_sorting.q         |   2 +
 ql/src/test/queries/clientnegative/input4.q     |   2 +
 .../queries/clientnegative/input_part0_neg.q    |   2 +
 .../insertover_dynapart_ifnotexists.q           |   2 +
 .../test/queries/clientnegative/strict_join.q   |   2 +
 .../queries/clientnegative/strict_orderby.q     |   2 +
 .../queries/clientnegative/strict_pruning.q     |   2 +
 .../alter_concatenate_indexed_table.q           |   2 +
 .../test/queries/clientpositive/alter_merge.q   |   2 +
 .../test/queries/clientpositive/alter_merge_2.q |   2 +
 .../queries/clientpositive/alter_merge_stats.q  |   2 +
 .../queries/clientpositive/autoColumnStats_1.q  |   2 +
 .../queries/clientpositive/autoColumnStats_2.q  |   2 +
 .../clientpositive/auto_sortmerge_join_1.q      |   2 +
 .../clientpositive/auto_sortmerge_join_11.q     |   2 +
 .../clientpositive/auto_sortmerge_join_12.q     |   2 +
 .../clientpositive/auto_sortmerge_join_16.q     |   2 +
 .../clientpositive/auto_sortmerge_join_2.q      |   2 +
 .../clientpositive/auto_sortmerge_join_3.q      |   2 +
 .../clientpositive/auto_sortmerge_join_4.q      |   2 +
 .../clientpositive/auto_sortmerge_join_5.q      |   2 +
 .../clientpositive/auto_sortmerge_join_7.q      |   2 +
 .../clientpositive/auto_sortmerge_join_8.q      |   2 +
 .../queries/clientpositive/bucket_map_join_1.q  |   2 +
 .../queries/clientpositive/bucket_map_join_2.q  |   2 +
 .../clientpositive/bucket_map_join_spark1.q     |   2 +
 .../clientpositive/bucket_map_join_spark2.q     |   2 +
 .../clientpositive/bucket_map_join_spark3.q     |   2 +
 .../clientpositive/bucket_map_join_tez1.q       |   2 +
 .../clientpositive/bucket_map_join_tez2.q       |   2 +
 .../queries/clientpositive/bucketcontext_1.q    |   2 +
 .../queries/clientpositive/bucketcontext_2.q    |   2 +
 .../queries/clientpositive/bucketcontext_3.q    |   2 +
 .../queries/clientpositive/bucketcontext_4.q    |   2 +
 .../queries/clientpositive/bucketcontext_5.q    |   2 +
 .../queries/clientpositive/bucketcontext_6.q    |   2 +
 .../queries/clientpositive/bucketcontext_7.q    |   2 +
 .../queries/clientpositive/bucketcontext_8.q    |   2 +
 .../bucketizedhiveinputformat_auto.q            |   2 +
 .../queries/clientpositive/bucketmapjoin1.q     |   2 +
 .../queries/clientpositive/bucketmapjoin10.q    |   2 +
 .../queries/clientpositive/bucketmapjoin11.q    |   2 +
 .../queries/clientpositive/bucketmapjoin12.q    |   2 +
 .../queries/clientpositive/bucketmapjoin2.q     |   2 +
 .../queries/clientpositive/bucketmapjoin3.q     |   2 +
 .../queries/clientpositive/bucketmapjoin4.q     |   2 +
 .../queries/clientpositive/bucketmapjoin5.q     |   2 +
 .../queries/clientpositive/bucketmapjoin7.q     |   2 +
 .../queries/clientpositive/bucketmapjoin8.q     |   2 +
 .../queries/clientpositive/bucketmapjoin9.q     |   2 +
 .../clientpositive/bucketmapjoin_negative.q     |   2 +
 .../clientpositive/bucketmapjoin_negative2.q    |   2 +
 .../clientpositive/bucketmapjoin_negative3.q    |   2 +
 .../cbo_rp_udaf_percentile_approx_23.q          |   2 +
 ql/src/test/queries/clientpositive/char_1.q     |   2 +
 ql/src/test/queries/clientpositive/char_serde.q |   2 +
 .../clientpositive/create_merge_compressed.q    |   2 +
 .../queries/clientpositive/explainanalyze_2.q   |   2 +
 .../queries/clientpositive/explainanalyze_3.q   |   2 +
 .../test/queries/clientpositive/explainuser_1.q |   2 +
 .../test/queries/clientpositive/explainuser_2.q |   2 +
 .../test/queries/clientpositive/explainuser_3.q |   2 +
 .../test/queries/clientpositive/global_limit.q  |   2 +
 .../clientpositive/infer_bucket_sort_dyn_part.q |   2 +
 .../queries/clientpositive/insert_orig_table.q  |   2 +
 .../clientpositive/insert_values_orig_table.q   |   2 +
 .../insert_values_orig_table_use_metadata.q     |   2 +
 .../clientpositive/merge_dynamic_partition.q    |   2 +
 .../clientpositive/merge_dynamic_partition2.q   |   2 +
 .../clientpositive/merge_dynamic_partition3.q   |   2 +
 .../clientpositive/merge_dynamic_partition4.q   |   2 +
 .../clientpositive/merge_dynamic_partition5.q   |   2 +
 ql/src/test/queries/clientpositive/mergejoin.q  |   2 +
 .../test/queries/clientpositive/smb_mapjoin_1.q |   2 +
 .../queries/clientpositive/smb_mapjoin_10.q     |   2 +
 .../test/queries/clientpositive/smb_mapjoin_2.q |   2 +
 .../queries/clientpositive/smb_mapjoin_25.q     |   2 +
 .../test/queries/clientpositive/smb_mapjoin_3.q |   2 +
 .../test/queries/clientpositive/smb_mapjoin_4.q |   2 +
 .../test/queries/clientpositive/smb_mapjoin_5.q |   2 +
 .../test/queries/clientpositive/smb_mapjoin_7.q |   2 +
 .../test/queries/clientpositive/smb_mapjoin_8.q |   2 +
 ql/src/test/queries/clientpositive/stats1.q     |   2 +
 ql/src/test/queries/clientpositive/stats11.q    |   2 +
 ql/src/test/queries/clientpositive/stats18.q    |   2 +
 ql/src/test/queries/clientpositive/tez_fsstat.q |   2 +
 ql/src/test/queries/clientpositive/tez_smb_1.q  |   2 +
 .../test/queries/clientpositive/tez_smb_empty.q |   2 +
 .../test/queries/clientpositive/tez_smb_main.q  |   2 +
 .../clientpositive/udaf_percentile_approx_20.q  |   2 +
 .../clientpositive/udaf_percentile_approx_23.q  |   2 +
 ql/src/test/queries/clientpositive/varchar_1.q  |   2 +
 .../test/queries/clientpositive/varchar_serde.q |   2 +
 .../clientnegative/alter_view_failure6.q.out    |   2 +-
 .../clientnegative/compare_double_bigint.q.out  |   2 +-
 .../clientnegative/compare_string_bigint.q.out  |   2 +-
 ql/src/test/results/clientnegative/input4.q.out |   2 +-
 .../clientnegative/input_part0_neg.q.out        |   2 +-
 .../results/clientnegative/strict_join.q.out    |   2 +-
 .../results/clientnegative/strict_orderby.q.out |   2 +-
 .../results/clientnegative/strict_pruning.q.out |   2 +-
 .../test/results/clientpositive/sample2.q.out   | 934 +++++++++----------
 .../test/results/clientpositive/sample4.q.out   | 934 +++++++++----------
 .../test/results/clientpositive/sample6.q.out   | 701 +++++++++-----
 .../test/results/clientpositive/sample7.q.out   | 362 +++----
 .../test/results/clientpositive/sample9.q.out   | 934 +++++++++----------
 .../results/clientpositive/spark/sample2.q.out  |   4 +-
 .../results/clientpositive/spark/sample4.q.out  |   4 +-
 .../results/clientpositive/spark/sample6.q.out  | 249 ++++-
 .../results/clientpositive/spark/sample7.q.out  |   4 +-
 121 files changed, 2537 insertions(+), 1856 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java
----------------------------------------------------------------------
diff --git a/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java b/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java
index 200a1ad..a9474c4 100644
--- a/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java
+++ b/common/src/java/org/apache/hadoop/hive/conf/HiveConf.java
@@ -1024,8 +1024,12 @@ public class HiveConf extends Configuration {
         "  Comparing bigints and strings.\n" +
         "  Comparing bigints and doubles."),
     HIVE_STRICT_CHECKS_CARTESIAN("hive.strict.checks.cartesian.product", true,
-        "Enabling strict large query checks disallows the following:\n" +
+        "Enabling strict Cartesian join checks disallows the following:\n" +
         "  Cartesian product (cross join)."),
+    HIVE_STRICT_CHECKS_BUCKETING("hive.strict.checks.bucketing", true,
+        "Enabling strict bucketing checks disallows the following:\n" +
+        "  Load into bucketed tables."),
+
     @Deprecated
     HIVEMAPREDMODE("hive.mapred.mode", null,
         "Deprecated; use hive.strict.checks.* settings instead."),
@@ -4336,11 +4340,14 @@ public class HiveConf extends Configuration {
         "Unsafe compares between different types", ConfVars.HIVE_STRICT_CHECKS_TYPE_SAFETY);
     private static final String NO_CARTESIAN_MSG = makeMessage(
         "Cartesian products", ConfVars.HIVE_STRICT_CHECKS_CARTESIAN);
+    private static final String NO_BUCKETING_MSG = makeMessage(
+        "Load into bucketed tables", ConfVars.HIVE_STRICT_CHECKS_BUCKETING);
 
     private static String makeMessage(String what, ConfVars setting) {
-      return what + " are disabled for safety reasons. If you know what you are doing, please make"
-          + " sure that " + setting.varname + " is set to false and that "
-          + ConfVars.HIVEMAPREDMODE.varname + " is not set to 'strict' to enable them.";
+      return what + " are disabled for safety reasons. If you know what you are doing, please set"
+          + setting.varname + " to false and that " + ConfVars.HIVEMAPREDMODE.varname + " is not"
+          + " set to 'strict' to proceed. Note that if you may get errors or incorrect results if"
+          + " you make a mistake while using some of the unsafe features.";
     }
 
     public static String checkNoLimit(Configuration conf) {
@@ -4360,6 +4367,10 @@ public class HiveConf extends Configuration {
       return isAllowed(conf, ConfVars.HIVE_STRICT_CHECKS_CARTESIAN) ? null : NO_CARTESIAN_MSG;
     }
 
+    public static String checkBucketing(Configuration conf) {
+      return isAllowed(conf, ConfVars.HIVE_STRICT_CHECKS_BUCKETING) ? null : NO_BUCKETING_MSG;
+    }
+
     private static boolean isAllowed(Configuration conf, ConfVars setting) {
       String mode = HiveConf.getVar(conf, ConfVars.HIVEMAPREDMODE, (String)null);
       return (mode != null) ? !"strict".equals(mode) : !HiveConf.getBoolVar(conf, setting);

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/data/scripts/q_test_init.sql
----------------------------------------------------------------------
diff --git a/data/scripts/q_test_init.sql b/data/scripts/q_test_init.sql
index 0c8668c..37a6d95 100644
--- a/data/scripts/q_test_init.sql
+++ b/data/scripts/q_test_init.sql
@@ -70,14 +70,18 @@ ANALYZE TABLE src_thrift COMPUTE STATISTICS;
 --
 -- Table srcbucket
 --
+DROP TABLE IF EXISTS srcbucket_tmp;
 DROP TABLE IF EXISTS srcbucket;
 
+CREATE TABLE srcbucket_tmp (key INT, value STRING) STORED AS TEXTFILE;
 CREATE TABLE srcbucket (key INT, value STRING)
 CLUSTERED BY (key) INTO 2 BUCKETS
 STORED AS TEXTFILE;
 
-LOAD DATA LOCAL INPATH "${hiveconf:test.data.dir}/srcbucket0.txt" INTO TABLE srcbucket;
-LOAD DATA LOCAL INPATH "${hiveconf:test.data.dir}/srcbucket1.txt" INTO TABLE srcbucket;
+LOAD DATA LOCAL INPATH "${hiveconf:test.data.dir}/srcbucket0.txt" INTO TABLE srcbucket_tmp;
+LOAD DATA LOCAL INPATH "${hiveconf:test.data.dir}/srcbucket1.txt" INTO TABLE srcbucket_tmp;
+INSERT INTO srcbucket SELECT * FROM srcbucket_tmp;
+DROP TABLE srcbucket_tmp;
  
 ANALYZE TABLE srcbucket COMPUTE STATISTICS;
 
@@ -86,16 +90,20 @@ ANALYZE TABLE srcbucket COMPUTE STATISTICS FOR COLUMNS key,value;
 --
 -- Table srcbucket2
 --
+DROP TABLE IF EXISTS srcbucket_tmp;
 DROP TABLE IF EXISTS srcbucket2;
 
+CREATE TABLE srcbucket_tmp (key INT, value STRING);
 CREATE TABLE srcbucket2 (key INT, value STRING)
 CLUSTERED BY (key) INTO 4 BUCKETS
 STORED AS TEXTFILE;
 
-LOAD DATA LOCAL INPATH "${hiveconf:test.data.dir}/srcbucket20.txt" INTO TABLE srcbucket2;
-LOAD DATA LOCAL INPATH "${hiveconf:test.data.dir}/srcbucket21.txt" INTO TABLE srcbucket2;
-LOAD DATA LOCAL INPATH "${hiveconf:test.data.dir}/srcbucket22.txt" INTO TABLE srcbucket2;
-LOAD DATA LOCAL INPATH "${hiveconf:test.data.dir}/srcbucket23.txt" INTO TABLE srcbucket2;
+LOAD DATA LOCAL INPATH "${hiveconf:test.data.dir}/srcbucket20.txt" INTO TABLE srcbucket_tmp;
+LOAD DATA LOCAL INPATH "${hiveconf:test.data.dir}/srcbucket21.txt" INTO TABLE srcbucket_tmp;
+LOAD DATA LOCAL INPATH "${hiveconf:test.data.dir}/srcbucket22.txt" INTO TABLE srcbucket_tmp;
+LOAD DATA LOCAL INPATH "${hiveconf:test.data.dir}/srcbucket23.txt" INTO TABLE srcbucket_tmp;
+INSERT INTO srcbucket2 SELECT * FROM srcbucket_tmp;
+DROP TABLE srcbucket_tmp;
 
 ANALYZE TABLE srcbucket2 COMPUTE STATISTICS;
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/java/org/apache/hadoop/hive/ql/parse/LoadSemanticAnalyzer.java
----------------------------------------------------------------------
diff --git a/ql/src/java/org/apache/hadoop/hive/ql/parse/LoadSemanticAnalyzer.java b/ql/src/java/org/apache/hadoop/hive/ql/parse/LoadSemanticAnalyzer.java
index 6726d44..bda94ff 100644
--- a/ql/src/java/org/apache/hadoop/hive/ql/parse/LoadSemanticAnalyzer.java
+++ b/ql/src/java/org/apache/hadoop/hive/ql/parse/LoadSemanticAnalyzer.java
@@ -18,6 +18,10 @@
 
 package org.apache.hadoop.hive.ql.parse;
 
+import org.apache.hadoop.hive.conf.HiveConf.StrictChecks;
+
+import org.apache.hadoop.hive.conf.HiveConf.ConfVars;
+
 import java.io.IOException;
 import java.io.Serializable;
 import java.net.URI;
@@ -215,6 +219,12 @@ public class LoadSemanticAnalyzer extends BaseSemanticAnalyzer {
         && (ts.partSpec == null || ts.partSpec.size() == 0)) {
       throw new SemanticException(ErrorMsg.NEED_PARTITION_ERROR.getMsg());
     }
+    List<String> bucketCols = ts.tableHandle.getBucketCols();
+    if (bucketCols != null && !bucketCols.isEmpty()) {
+      String error = StrictChecks.checkBucketing(conf);
+      if (error != null) throw new SemanticException("Please load into an intermediate table"
+          + " and use 'insert... select' to allow Hive to enforce bucketing. " + error);
+    }
 
     // make sure the arguments make sense
     List<FileStatus> files = applyConstraintsAndGetFiles(fromURI, fromTree, isLocal);

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientnegative/alter_concatenate_indexed_table.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientnegative/alter_concatenate_indexed_table.q b/ql/src/test/queries/clientnegative/alter_concatenate_indexed_table.q
index 4193315..6de8c7f 100644
--- a/ql/src/test/queries/clientnegative/alter_concatenate_indexed_table.q
+++ b/ql/src/test/queries/clientnegative/alter_concatenate_indexed_table.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.exec.concatenate.check.index=true;
 create table src_rc_concatenate_test(key int, value string) stored as rcfile;
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientnegative/alter_view_failure6.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientnegative/alter_view_failure6.q b/ql/src/test/queries/clientnegative/alter_view_failure6.q
index dab7b14..e390409 100644
--- a/ql/src/test/queries/clientnegative/alter_view_failure6.q
+++ b/ql/src/test/queries/clientnegative/alter_view_failure6.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false; 
+
 DROP VIEW xxx7;
 CREATE VIEW xxx7
 PARTITIONED ON (key)

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientnegative/bucket_mapjoin_mismatch1.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientnegative/bucket_mapjoin_mismatch1.q b/ql/src/test/queries/clientnegative/bucket_mapjoin_mismatch1.q
index 7dce81f..ff982c6 100644
--- a/ql/src/test/queries/clientnegative/bucket_mapjoin_mismatch1.q
+++ b/ql/src/test/queries/clientnegative/bucket_mapjoin_mismatch1.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 CREATE TABLE srcbucket_mapjoin_part (key int, value string) 
   partitioned by (ds string) CLUSTERED BY (key) INTO 3 BUCKETS

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientnegative/bucket_mapjoin_wrong_table_metadata_1.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientnegative/bucket_mapjoin_wrong_table_metadata_1.q b/ql/src/test/queries/clientnegative/bucket_mapjoin_wrong_table_metadata_1.q
index 802fcd9..fa91552 100644
--- a/ql/src/test/queries/clientnegative/bucket_mapjoin_wrong_table_metadata_1.q
+++ b/ql/src/test/queries/clientnegative/bucket_mapjoin_wrong_table_metadata_1.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false; 
+
 -- Although the user has specified a bucketed map-join, the number of buckets in the table
 -- do not match the number of files
 drop table table1;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientnegative/bucket_mapjoin_wrong_table_metadata_2.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientnegative/bucket_mapjoin_wrong_table_metadata_2.q b/ql/src/test/queries/clientnegative/bucket_mapjoin_wrong_table_metadata_2.q
index ac5abeb..b392c42 100644
--- a/ql/src/test/queries/clientnegative/bucket_mapjoin_wrong_table_metadata_2.q
+++ b/ql/src/test/queries/clientnegative/bucket_mapjoin_wrong_table_metadata_2.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false; 
+
 -- Although the user has specified a bucketed map-join, the number of buckets in the table
 -- do not match the number of files
 drop table table1;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientnegative/compare_double_bigint.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientnegative/compare_double_bigint.q b/ql/src/test/queries/clientnegative/compare_double_bigint.q
index f85c526..6580d88 100644
--- a/ql/src/test/queries/clientnegative/compare_double_bigint.q
+++ b/ql/src/test/queries/clientnegative/compare_double_bigint.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false; 
+
 set hive.mapred.mode=strict;
 
 -- This should fail until we fix the issue with precision when casting a bigint to a double

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientnegative/compare_string_bigint.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientnegative/compare_string_bigint.q b/ql/src/test/queries/clientnegative/compare_string_bigint.q
index 810f65d..ed81637 100644
--- a/ql/src/test/queries/clientnegative/compare_string_bigint.q
+++ b/ql/src/test/queries/clientnegative/compare_string_bigint.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false; 
+
 set hive.mapred.mode=strict;
 
 --This should fail until we fix the issue with precision when casting a bigint to a double

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientnegative/dynamic_partitions_with_whitelist.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientnegative/dynamic_partitions_with_whitelist.q b/ql/src/test/queries/clientnegative/dynamic_partitions_with_whitelist.q
index 8623db8..e6b7a9f 100644
--- a/ql/src/test/queries/clientnegative/dynamic_partitions_with_whitelist.q
+++ b/ql/src/test/queries/clientnegative/dynamic_partitions_with_whitelist.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 SET hive.metastore.partition.name.whitelist.pattern=[^9]*;
 set hive.exec.failure.hooks=org.apache.hadoop.hive.ql.hooks.VerifyTableDirectoryIsEmptyHook;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientnegative/exim_11_nonpart_noncompat_sorting.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientnegative/exim_11_nonpart_noncompat_sorting.q b/ql/src/test/queries/clientnegative/exim_11_nonpart_noncompat_sorting.q
index 990a686..1d9ae35 100644
--- a/ql/src/test/queries/clientnegative/exim_11_nonpart_noncompat_sorting.q
+++ b/ql/src/test/queries/clientnegative/exim_11_nonpart_noncompat_sorting.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false; 
+
 set hive.test.mode=true;
 set hive.test.mode.prefix=;
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientnegative/input4.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientnegative/input4.q b/ql/src/test/queries/clientnegative/input4.q
index 60aea32..03cf127 100644
--- a/ql/src/test/queries/clientnegative/input4.q
+++ b/ql/src/test/queries/clientnegative/input4.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false; 
+
 set hive.mapred.mode=strict;
 
 select * from srcpart a join

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientnegative/input_part0_neg.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientnegative/input_part0_neg.q b/ql/src/test/queries/clientnegative/input_part0_neg.q
index 4656693..14f947c 100644
--- a/ql/src/test/queries/clientnegative/input_part0_neg.q
+++ b/ql/src/test/queries/clientnegative/input_part0_neg.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false; 
+
 set hive.mapred.mode=strict;
 
 SELECT x.* FROM SRCPART x WHERE key = '2008-04-08';

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientnegative/insertover_dynapart_ifnotexists.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientnegative/insertover_dynapart_ifnotexists.q b/ql/src/test/queries/clientnegative/insertover_dynapart_ifnotexists.q
index a8f77c2..173dbd0 100644
--- a/ql/src/test/queries/clientnegative/insertover_dynapart_ifnotexists.q
+++ b/ql/src/test/queries/clientnegative/insertover_dynapart_ifnotexists.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.exec.dynamic.partition=true;
 
 create table srcpart_dp like srcpart;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientnegative/strict_join.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientnegative/strict_join.q b/ql/src/test/queries/clientnegative/strict_join.q
index d618ee2..48b4a60 100644
--- a/ql/src/test/queries/clientnegative/strict_join.q
+++ b/ql/src/test/queries/clientnegative/strict_join.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false; 
+
 set hive.mapred.mode=strict;
 
 SELECT *  FROM src src1 JOIN src src2;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientnegative/strict_orderby.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientnegative/strict_orderby.q b/ql/src/test/queries/clientnegative/strict_orderby.q
index 781cdbb..928b067 100644
--- a/ql/src/test/queries/clientnegative/strict_orderby.q
+++ b/ql/src/test/queries/clientnegative/strict_orderby.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false; 
+
 set hive.mapred.mode=strict;
 
 EXPLAIN

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientnegative/strict_pruning.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientnegative/strict_pruning.q b/ql/src/test/queries/clientnegative/strict_pruning.q
index 270ab2f..834ee82 100644
--- a/ql/src/test/queries/clientnegative/strict_pruning.q
+++ b/ql/src/test/queries/clientnegative/strict_pruning.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false; 
+
 set hive.mapred.mode=strict;
 
 EXPLAIN

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/alter_concatenate_indexed_table.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/alter_concatenate_indexed_table.q b/ql/src/test/queries/clientpositive/alter_concatenate_indexed_table.q
index d2bc440..3a9e14c 100644
--- a/ql/src/test/queries/clientpositive/alter_concatenate_indexed_table.q
+++ b/ql/src/test/queries/clientpositive/alter_concatenate_indexed_table.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 set hive.exec.concatenate.check.index =false;
 create table src_rc_concatenate_test(key int, value string) stored as rcfile;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/alter_merge.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/alter_merge.q b/ql/src/test/queries/clientpositive/alter_merge.q
index 0ff0294..1839005 100644
--- a/ql/src/test/queries/clientpositive/alter_merge.q
+++ b/ql/src/test/queries/clientpositive/alter_merge.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 create table src_rc_merge_test(key int, value string) stored as rcfile;
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/alter_merge_2.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/alter_merge_2.q b/ql/src/test/queries/clientpositive/alter_merge_2.q
index e09703d..b0dd56c 100644
--- a/ql/src/test/queries/clientpositive/alter_merge_2.q
+++ b/ql/src/test/queries/clientpositive/alter_merge_2.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 create table src_rc_merge_test_part(key int, value string) partitioned by (ds string, ts string) stored as rcfile;
 
 alter table src_rc_merge_test_part add partition (ds='2012-01-03', ts='2012-01-03+14:46:31');

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/alter_merge_stats.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/alter_merge_stats.q b/ql/src/test/queries/clientpositive/alter_merge_stats.q
index 0af87e2..fedf1a1 100644
--- a/ql/src/test/queries/clientpositive/alter_merge_stats.q
+++ b/ql/src/test/queries/clientpositive/alter_merge_stats.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 create table src_rc_merge_test_stat(key int, value string) stored as rcfile;
 
 load data local inpath '../../data/files/smbbucket_1.rc' into table src_rc_merge_test_stat;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/autoColumnStats_1.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/autoColumnStats_1.q b/ql/src/test/queries/clientpositive/autoColumnStats_1.q
index bb7252a..7955b07 100644
--- a/ql/src/test/queries/clientpositive/autoColumnStats_1.q
+++ b/ql/src/test/queries/clientpositive/autoColumnStats_1.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.stats.column.autogather=true;
 set hive.stats.fetch.column.stats=true;
 set hive.exec.dynamic.partition=true;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/autoColumnStats_2.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/autoColumnStats_2.q b/ql/src/test/queries/clientpositive/autoColumnStats_2.q
index c1abcb1..de86036 100644
--- a/ql/src/test/queries/clientpositive/autoColumnStats_2.q
+++ b/ql/src/test/queries/clientpositive/autoColumnStats_2.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.stats.column.autogather=true;
 set hive.stats.fetch.column.stats=true;
 set hive.exec.dynamic.partition=true;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/auto_sortmerge_join_1.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/auto_sortmerge_join_1.q b/ql/src/test/queries/clientpositive/auto_sortmerge_join_1.q
index 6c2fbba..a1d5249 100644
--- a/ql/src/test/queries/clientpositive/auto_sortmerge_join_1.q
+++ b/ql/src/test/queries/clientpositive/auto_sortmerge_join_1.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- small 1 part, 2 bucket & big 2 part, 4 bucket
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/auto_sortmerge_join_11.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/auto_sortmerge_join_11.q b/ql/src/test/queries/clientpositive/auto_sortmerge_join_11.q
index aa345b5..b1c60f2 100644
--- a/ql/src/test/queries/clientpositive/auto_sortmerge_join_11.q
+++ b/ql/src/test/queries/clientpositive/auto_sortmerge_join_11.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- small 1 part, 2 bucket & big 2 part, 4 bucket
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/auto_sortmerge_join_12.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/auto_sortmerge_join_12.q b/ql/src/test/queries/clientpositive/auto_sortmerge_join_12.q
index b344bd0..b512cc5 100644
--- a/ql/src/test/queries/clientpositive/auto_sortmerge_join_12.q
+++ b/ql/src/test/queries/clientpositive/auto_sortmerge_join_12.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- small 1 part, 2 bucket & big 2 part, 4 bucket
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/auto_sortmerge_join_16.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/auto_sortmerge_join_16.q b/ql/src/test/queries/clientpositive/auto_sortmerge_join_16.q
index 83b67f8..12ab1fa 100644
--- a/ql/src/test/queries/clientpositive/auto_sortmerge_join_16.q
+++ b/ql/src/test/queries/clientpositive/auto_sortmerge_join_16.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.auto.convert.join=true;
 
 set hive.exec.dynamic.partition.mode=nonstrict;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/auto_sortmerge_join_2.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/auto_sortmerge_join_2.q b/ql/src/test/queries/clientpositive/auto_sortmerge_join_2.q
index 2cf809b..e77d937 100644
--- a/ql/src/test/queries/clientpositive/auto_sortmerge_join_2.q
+++ b/ql/src/test/queries/clientpositive/auto_sortmerge_join_2.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- small 1 part, 4 bucket & big 2 part, 2 bucket
 CREATE TABLE bucket_small (key string, value string) partitioned by (ds string) CLUSTERED BY (key) SORTED BY (key) INTO 4 BUCKETS STORED AS TEXTFILE;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/auto_sortmerge_join_3.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/auto_sortmerge_join_3.q b/ql/src/test/queries/clientpositive/auto_sortmerge_join_3.q
index b14b32b..183f033 100644
--- a/ql/src/test/queries/clientpositive/auto_sortmerge_join_3.q
+++ b/ql/src/test/queries/clientpositive/auto_sortmerge_join_3.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- small 2 part, 2 bucket & big 1 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;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/auto_sortmerge_join_4.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/auto_sortmerge_join_4.q b/ql/src/test/queries/clientpositive/auto_sortmerge_join_4.q
index b08649e..21f273a 100644
--- a/ql/src/test/queries/clientpositive/auto_sortmerge_join_4.q
+++ b/ql/src/test/queries/clientpositive/auto_sortmerge_join_4.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- small 2 part, 4 bucket & big 1 part, 2 bucket
 CREATE TABLE bucket_small (key string, value string) partitioned by (ds string) CLUSTERED BY (key) SORTED BY (key) INTO 4 BUCKETS STORED AS TEXTFILE;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/auto_sortmerge_join_5.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/auto_sortmerge_join_5.q b/ql/src/test/queries/clientpositive/auto_sortmerge_join_5.q
index 489f556..8ca04d6 100644
--- a/ql/src/test/queries/clientpositive/auto_sortmerge_join_5.q
+++ b/ql/src/test/queries/clientpositive/auto_sortmerge_join_5.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- small no part, 4 bucket & big no part, 2 bucket
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/auto_sortmerge_join_7.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/auto_sortmerge_join_7.q b/ql/src/test/queries/clientpositive/auto_sortmerge_join_7.q
index 161bc8a..cf12331 100644
--- a/ql/src/test/queries/clientpositive/auto_sortmerge_join_7.q
+++ b/ql/src/test/queries/clientpositive/auto_sortmerge_join_7.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- small 2 part, 4 bucket & big 2 part, 2 bucket
 CREATE TABLE bucket_small (key string, value string) partitioned by (ds string) CLUSTERED BY (key) SORTED BY (key) INTO 4 BUCKETS STORED AS TEXTFILE;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/auto_sortmerge_join_8.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/auto_sortmerge_join_8.q b/ql/src/test/queries/clientpositive/auto_sortmerge_join_8.q
index cc2ba28..5ec4e26 100644
--- a/ql/src/test/queries/clientpositive/auto_sortmerge_join_8.q
+++ b/ql/src/test/queries/clientpositive/auto_sortmerge_join_8.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 set hive.exec.submitviachild=false;
 set hive.exec.submit.local.task.via.child=false;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucket_map_join_1.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucket_map_join_1.q b/ql/src/test/queries/clientpositive/bucket_map_join_1.q
index deae460..a92ffa4 100644
--- a/ql/src/test/queries/clientpositive/bucket_map_join_1.q
+++ b/ql/src/test/queries/clientpositive/bucket_map_join_1.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 drop table table1;
 drop table table2;
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucket_map_join_2.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucket_map_join_2.q b/ql/src/test/queries/clientpositive/bucket_map_join_2.q
index f416706..4aa6f57 100644
--- a/ql/src/test/queries/clientpositive/bucket_map_join_2.q
+++ b/ql/src/test/queries/clientpositive/bucket_map_join_2.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 drop table table1;
 drop table table2;
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucket_map_join_spark1.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucket_map_join_spark1.q b/ql/src/test/queries/clientpositive/bucket_map_join_spark1.q
index 3f9ccc4..9018b4e 100644
--- a/ql/src/test/queries/clientpositive/bucket_map_join_spark1.q
+++ b/ql/src/test/queries/clientpositive/bucket_map_join_spark1.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 CREATE TABLE srcbucket_mapjoin_part (key int, value string) partitioned by (ds string) CLUSTERED BY (key) INTO 4 BUCKETS STORED AS TEXTFILE;
 load data local inpath '../../data/files/srcbucket20.txt' INTO TABLE srcbucket_mapjoin_part partition(ds='2008-04-08');

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucket_map_join_spark2.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucket_map_join_spark2.q b/ql/src/test/queries/clientpositive/bucket_map_join_spark2.q
index 4a70671..6f54737 100644
--- a/ql/src/test/queries/clientpositive/bucket_map_join_spark2.q
+++ b/ql/src/test/queries/clientpositive/bucket_map_join_spark2.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 CREATE TABLE srcbucket_mapjoin_part (key int, value string) partitioned by (ds string) CLUSTERED BY (key) INTO 4 BUCKETS STORED AS TEXTFILE;
 load data local inpath '../../data/files/srcbucket20.txt' INTO TABLE srcbucket_mapjoin_part partition(ds='2008-04-08');

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucket_map_join_spark3.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucket_map_join_spark3.q b/ql/src/test/queries/clientpositive/bucket_map_join_spark3.q
index 9ae7986..26a8d48 100644
--- a/ql/src/test/queries/clientpositive/bucket_map_join_spark3.q
+++ b/ql/src/test/queries/clientpositive/bucket_map_join_spark3.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 CREATE TABLE srcbucket_mapjoin_part (key int, value string) partitioned by (ds string) CLUSTERED BY (key) INTO 2 BUCKETS STORED AS TEXTFILE;
 load data local inpath '../../data/files/srcbucket22.txt' INTO TABLE srcbucket_mapjoin_part partition(ds='2008-04-08');

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucket_map_join_tez1.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucket_map_join_tez1.q b/ql/src/test/queries/clientpositive/bucket_map_join_tez1.q
index ade04dd..aeb244a 100644
--- a/ql/src/test/queries/clientpositive/bucket_map_join_tez1.q
+++ b/ql/src/test/queries/clientpositive/bucket_map_join_tez1.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 set hive.explain.user=false;
 set hive.auto.convert.join=true;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucket_map_join_tez2.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucket_map_join_tez2.q b/ql/src/test/queries/clientpositive/bucket_map_join_tez2.q
index fd997df..37989ec 100644
--- a/ql/src/test/queries/clientpositive/bucket_map_join_tez2.q
+++ b/ql/src/test/queries/clientpositive/bucket_map_join_tez2.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 set hive.explain.user=false;
 set hive.auto.convert.join=true;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketcontext_1.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketcontext_1.q b/ql/src/test/queries/clientpositive/bucketcontext_1.q
index ad0f473..d663da4 100644
--- a/ql/src/test/queries/clientpositive/bucketcontext_1.q
+++ b/ql/src/test/queries/clientpositive/bucketcontext_1.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- 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;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketcontext_2.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketcontext_2.q b/ql/src/test/queries/clientpositive/bucketcontext_2.q
index 931f55a..cf79a17 100644
--- a/ql/src/test/queries/clientpositive/bucketcontext_2.q
+++ b/ql/src/test/queries/clientpositive/bucketcontext_2.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- small 1 part, 4 bucket & big 2 part, 2 bucket
 CREATE TABLE bucket_small (key string, value string) partitioned by (ds string) CLUSTERED BY (key) SORTED BY (key) INTO 4 BUCKETS STORED AS TEXTFILE;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketcontext_3.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketcontext_3.q b/ql/src/test/queries/clientpositive/bucketcontext_3.q
index e03b285..983ddbe 100644
--- a/ql/src/test/queries/clientpositive/bucketcontext_3.q
+++ b/ql/src/test/queries/clientpositive/bucketcontext_3.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- small 2 part, 2 bucket & big 1 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;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketcontext_4.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketcontext_4.q b/ql/src/test/queries/clientpositive/bucketcontext_4.q
index af08f07..83a9d46 100644
--- a/ql/src/test/queries/clientpositive/bucketcontext_4.q
+++ b/ql/src/test/queries/clientpositive/bucketcontext_4.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- small 2 part, 4 bucket & big 1 part, 2 bucket
 CREATE TABLE bucket_small (key string, value string) partitioned by (ds string) CLUSTERED BY (key) SORTED BY (key) INTO 4 BUCKETS STORED AS TEXTFILE;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketcontext_5.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketcontext_5.q b/ql/src/test/queries/clientpositive/bucketcontext_5.q
index 5078072..4c753b9 100644
--- a/ql/src/test/queries/clientpositive/bucketcontext_5.q
+++ b/ql/src/test/queries/clientpositive/bucketcontext_5.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 -- small no part, 4 bucket & big no part, 2 bucket
 CREATE TABLE bucket_small (key string, value string) CLUSTERED BY (key) SORTED BY (key) INTO 4 BUCKETS STORED AS TEXTFILE;
 load data local inpath '../../data/files/srcsortbucket1outof4.txt' INTO TABLE bucket_small;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketcontext_6.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketcontext_6.q b/ql/src/test/queries/clientpositive/bucketcontext_6.q
index 5549f3b..a224dac 100644
--- a/ql/src/test/queries/clientpositive/bucketcontext_6.q
+++ b/ql/src/test/queries/clientpositive/bucketcontext_6.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- small no part, 4 bucket & big 2 part, 2 bucket
 CREATE TABLE bucket_small (key string, value string) CLUSTERED BY (key) SORTED BY (key) INTO 4 BUCKETS STORED AS TEXTFILE;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketcontext_7.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketcontext_7.q b/ql/src/test/queries/clientpositive/bucketcontext_7.q
index 44cdb5e..ef3a51a 100644
--- a/ql/src/test/queries/clientpositive/bucketcontext_7.q
+++ b/ql/src/test/queries/clientpositive/bucketcontext_7.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- small 2 part, 4 bucket & big 2 part, 2 bucket
 CREATE TABLE bucket_small (key string, value string) partitioned by (ds string) CLUSTERED BY (key) SORTED BY (key) INTO 4 BUCKETS STORED AS TEXTFILE;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketcontext_8.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketcontext_8.q b/ql/src/test/queries/clientpositive/bucketcontext_8.q
index bb655e2..3c7b168 100644
--- a/ql/src/test/queries/clientpositive/bucketcontext_8.q
+++ b/ql/src/test/queries/clientpositive/bucketcontext_8.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- small 2 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;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketizedhiveinputformat_auto.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketizedhiveinputformat_auto.q b/ql/src/test/queries/clientpositive/bucketizedhiveinputformat_auto.q
index a2b0bbe..8516909 100644
--- a/ql/src/test/queries/clientpositive/bucketizedhiveinputformat_auto.q
+++ b/ql/src/test/queries/clientpositive/bucketizedhiveinputformat_auto.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 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/srcsortbucket1outof4.txt' INTO TABLE bucket_small partition(ds='2008-04-08');

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketmapjoin1.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketmapjoin1.q b/ql/src/test/queries/clientpositive/bucketmapjoin1.q
index 2fd3804..ee27181 100644
--- a/ql/src/test/queries/clientpositive/bucketmapjoin1.q
+++ b/ql/src/test/queries/clientpositive/bucketmapjoin1.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 CREATE TABLE srcbucket_mapjoin(key int, value string) CLUSTERED BY (key) INTO 2 BUCKETS STORED AS TEXTFILE;
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketmapjoin10.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketmapjoin10.q b/ql/src/test/queries/clientpositive/bucketmapjoin10.q
index 09c0ae2..d9b7edf 100644
--- a/ql/src/test/queries/clientpositive/bucketmapjoin10.q
+++ b/ql/src/test/queries/clientpositive/bucketmapjoin10.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.input.format=org.apache.hadoop.hive.ql.io.HiveInputFormat;
 
 CREATE TABLE srcbucket_mapjoin_part_1 (key INT, value STRING) PARTITIONED BY (part STRING) 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketmapjoin11.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketmapjoin11.q b/ql/src/test/queries/clientpositive/bucketmapjoin11.q
index d330b77..3c630ef 100644
--- a/ql/src/test/queries/clientpositive/bucketmapjoin11.q
+++ b/ql/src/test/queries/clientpositive/bucketmapjoin11.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.input.format=org.apache.hadoop.hive.ql.io.HiveInputFormat;
 
 CREATE TABLE srcbucket_mapjoin_part_1 (key INT, value STRING) PARTITIONED BY (part STRING) 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketmapjoin12.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketmapjoin12.q b/ql/src/test/queries/clientpositive/bucketmapjoin12.q
index 43a9de4..4229c5c 100644
--- a/ql/src/test/queries/clientpositive/bucketmapjoin12.q
+++ b/ql/src/test/queries/clientpositive/bucketmapjoin12.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.input.format=org.apache.hadoop.hive.ql.io.HiveInputFormat;
 
 CREATE TABLE srcbucket_mapjoin_part_1 (key INT, value STRING) PARTITIONED BY (part STRING) 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketmapjoin2.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketmapjoin2.q b/ql/src/test/queries/clientpositive/bucketmapjoin2.q
index d14261f..3a9816b 100644
--- a/ql/src/test/queries/clientpositive/bucketmapjoin2.q
+++ b/ql/src/test/queries/clientpositive/bucketmapjoin2.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 CREATE TABLE srcbucket_mapjoin_part (key int, value string) partitioned by (ds string) CLUSTERED BY (key) INTO 4 BUCKETS STORED AS TEXTFILE;
 load data local inpath '../../data/files/srcbucket20.txt' INTO TABLE srcbucket_mapjoin_part partition(ds='2008-04-08');

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketmapjoin3.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketmapjoin3.q b/ql/src/test/queries/clientpositive/bucketmapjoin3.q
index 78c23d5..495d3a4 100644
--- a/ql/src/test/queries/clientpositive/bucketmapjoin3.q
+++ b/ql/src/test/queries/clientpositive/bucketmapjoin3.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 CREATE TABLE srcbucket_mapjoin(key int, value string) CLUSTERED BY (key) INTO 2 BUCKETS STORED AS TEXTFILE;
 load data local inpath '../../data/files/srcbucket20.txt' INTO TABLE srcbucket_mapjoin;
 load data local inpath '../../data/files/srcbucket21.txt' INTO TABLE srcbucket_mapjoin;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketmapjoin4.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketmapjoin4.q b/ql/src/test/queries/clientpositive/bucketmapjoin4.q
index 54626e7..ab9080c 100644
--- a/ql/src/test/queries/clientpositive/bucketmapjoin4.q
+++ b/ql/src/test/queries/clientpositive/bucketmapjoin4.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.input.format=org.apache.hadoop.hive.ql.io.HiveInputFormat;
 CREATE TABLE srcbucket_mapjoin(key int, value string) CLUSTERED BY (key) INTO 2 BUCKETS STORED AS TEXTFILE;
 load data local inpath '../../data/files/srcbucket20.txt' INTO TABLE srcbucket_mapjoin;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketmapjoin5.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketmapjoin5.q b/ql/src/test/queries/clientpositive/bucketmapjoin5.q
index 6c03bbb..385087e 100644
--- a/ql/src/test/queries/clientpositive/bucketmapjoin5.q
+++ b/ql/src/test/queries/clientpositive/bucketmapjoin5.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 CREATE TABLE srcbucket_mapjoin(key int, value string) CLUSTERED BY (key) INTO 2 BUCKETS STORED AS TEXTFILE;
 load data local inpath '../../data/files/srcbucket20.txt' INTO TABLE srcbucket_mapjoin;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketmapjoin7.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketmapjoin7.q b/ql/src/test/queries/clientpositive/bucketmapjoin7.q
index cd4efe7..3830e9d 100644
--- a/ql/src/test/queries/clientpositive/bucketmapjoin7.q
+++ b/ql/src/test/queries/clientpositive/bucketmapjoin7.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.input.format=org.apache.hadoop.hive.ql.io.HiveInputFormat;
 
 CREATE TABLE srcbucket_mapjoin_part_1 (key INT, value STRING) PARTITIONED BY (ds STRING, hr STRING) 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketmapjoin8.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketmapjoin8.q b/ql/src/test/queries/clientpositive/bucketmapjoin8.q
index f467ea6..99eeabd 100644
--- a/ql/src/test/queries/clientpositive/bucketmapjoin8.q
+++ b/ql/src/test/queries/clientpositive/bucketmapjoin8.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.input.format=org.apache.hadoop.hive.ql.io.HiveInputFormat;
 
 CREATE TABLE srcbucket_mapjoin_part_1 (key INT, value STRING) PARTITIONED BY (part STRING) 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketmapjoin9.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketmapjoin9.q b/ql/src/test/queries/clientpositive/bucketmapjoin9.q
index f1d5f58..13189bc 100644
--- a/ql/src/test/queries/clientpositive/bucketmapjoin9.q
+++ b/ql/src/test/queries/clientpositive/bucketmapjoin9.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.input.format=org.apache.hadoop.hive.ql.io.HiveInputFormat;
 
 CREATE TABLE srcbucket_mapjoin_part_1 (key INT, value STRING) PARTITIONED BY (part STRING) 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketmapjoin_negative.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketmapjoin_negative.q b/ql/src/test/queries/clientpositive/bucketmapjoin_negative.q
index ea140dd..0d84fdd 100644
--- a/ql/src/test/queries/clientpositive/bucketmapjoin_negative.q
+++ b/ql/src/test/queries/clientpositive/bucketmapjoin_negative.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 
 
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketmapjoin_negative2.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketmapjoin_negative2.q b/ql/src/test/queries/clientpositive/bucketmapjoin_negative2.q
index 36d34dc..93780dc 100644
--- a/ql/src/test/queries/clientpositive/bucketmapjoin_negative2.q
+++ b/ql/src/test/queries/clientpositive/bucketmapjoin_negative2.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 CREATE TABLE srcbucket_mapjoin(key int, value string) CLUSTERED BY (key) INTO 2 BUCKETS STORED AS TEXTFILE;
 load data local inpath '../../data/files/srcbucket20.txt' INTO TABLE srcbucket_mapjoin;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/bucketmapjoin_negative3.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/bucketmapjoin_negative3.q b/ql/src/test/queries/clientpositive/bucketmapjoin_negative3.q
index 6398fff..41569a2 100644
--- a/ql/src/test/queries/clientpositive/bucketmapjoin_negative3.q
+++ b/ql/src/test/queries/clientpositive/bucketmapjoin_negative3.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 drop table test1;
 drop table test2;
 drop table test3;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/cbo_rp_udaf_percentile_approx_23.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/cbo_rp_udaf_percentile_approx_23.q b/ql/src/test/queries/clientpositive/cbo_rp_udaf_percentile_approx_23.q
index 0f2d0dd..c7e6755 100644
--- a/ql/src/test/queries/clientpositive/cbo_rp_udaf_percentile_approx_23.q
+++ b/ql/src/test/queries/clientpositive/cbo_rp_udaf_percentile_approx_23.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 set hive.cbo.returnpath.hiveop=true;
 -- INCLUDE_HADOOP_MAJOR_VERSIONS(0.23)

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/char_1.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/char_1.q b/ql/src/test/queries/clientpositive/char_1.q
index e617a49..09987cb 100644
--- a/ql/src/test/queries/clientpositive/char_1.q
+++ b/ql/src/test/queries/clientpositive/char_1.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 -- SORT_QUERY_RESULTS
 
 drop table char1;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/char_serde.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/char_serde.q b/ql/src/test/queries/clientpositive/char_serde.q
index 4340b4d..3959ba5 100644
--- a/ql/src/test/queries/clientpositive/char_serde.q
+++ b/ql/src/test/queries/clientpositive/char_serde.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 drop table if exists char_serde_regex;
 drop table if exists char_serde_lb;
 drop table if exists char_serde_ls;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/create_merge_compressed.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/create_merge_compressed.q b/ql/src/test/queries/clientpositive/create_merge_compressed.q
index 483931b..995401b 100644
--- a/ql/src/test/queries/clientpositive/create_merge_compressed.q
+++ b/ql/src/test/queries/clientpositive/create_merge_compressed.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 create table src_rc_merge_test(key int, value string) stored as rcfile;
 
 load data local inpath '../../data/files/smbbucket_1.rc' into table src_rc_merge_test;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/explainanalyze_2.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/explainanalyze_2.q b/ql/src/test/queries/clientpositive/explainanalyze_2.q
index 8b3df87..9cfcf0d 100644
--- a/ql/src/test/queries/clientpositive/explainanalyze_2.q
+++ b/ql/src/test/queries/clientpositive/explainanalyze_2.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.explain.user=true;
 
 explain analyze

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/explainanalyze_3.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/explainanalyze_3.q b/ql/src/test/queries/clientpositive/explainanalyze_3.q
index 61f68a1..6ccdffb 100644
--- a/ql/src/test/queries/clientpositive/explainanalyze_3.q
+++ b/ql/src/test/queries/clientpositive/explainanalyze_3.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.security.authorization.manager=org.apache.hadoop.hive.ql.security.authorization.DefaultHiveAuthorizationProvider;
 set hive.metastore.filter.hook=org.apache.hadoop.hive.metastore.DefaultMetaStoreFilterHookImpl;
 set hive.mapred.mode=nonstrict;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/explainuser_1.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/explainuser_1.q b/ql/src/test/queries/clientpositive/explainuser_1.q
index 3791662..a6fbb54 100644
--- a/ql/src/test/queries/clientpositive/explainuser_1.q
+++ b/ql/src/test/queries/clientpositive/explainuser_1.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 set hive.explain.user=true;
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/explainuser_2.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/explainuser_2.q b/ql/src/test/queries/clientpositive/explainuser_2.q
index 3f8bdb4..ef0e31b 100644
--- a/ql/src/test/queries/clientpositive/explainuser_2.q
+++ b/ql/src/test/queries/clientpositive/explainuser_2.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.explain.user=true;
 set hive.metastore.aggregate.stats.cache.enabled=false;
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/explainuser_3.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/explainuser_3.q b/ql/src/test/queries/clientpositive/explainuser_3.q
index 57029f1..282629e 100644
--- a/ql/src/test/queries/clientpositive/explainuser_3.q
+++ b/ql/src/test/queries/clientpositive/explainuser_3.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.security.authorization.manager=org.apache.hadoop.hive.ql.security.authorization.DefaultHiveAuthorizationProvider;
 set hive.metastore.filter.hook=org.apache.hadoop.hive.metastore.DefaultMetaStoreFilterHookImpl;
 set hive.mapred.mode=nonstrict;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/global_limit.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/global_limit.q b/ql/src/test/queries/clientpositive/global_limit.q
index 8c5f2ea..eefaffd 100644
--- a/ql/src/test/queries/clientpositive/global_limit.q
+++ b/ql/src/test/queries/clientpositive/global_limit.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 set hive.limit.optimize.enable=true;
 set hive.limit.optimize.limit.file=2;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/infer_bucket_sort_dyn_part.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/infer_bucket_sort_dyn_part.q b/ql/src/test/queries/clientpositive/infer_bucket_sort_dyn_part.q
index 4937be4..5b5bf8e 100644
--- a/ql/src/test/queries/clientpositive/infer_bucket_sort_dyn_part.q
+++ b/ql/src/test/queries/clientpositive/infer_bucket_sort_dyn_part.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 set hive.exec.infer.bucket.sort=true;
 set hive.exec.infer.bucket.sort.num.buckets.power.two=true;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/insert_orig_table.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/insert_orig_table.q b/ql/src/test/queries/clientpositive/insert_orig_table.q
index 01fee4e..de408d9 100644
--- a/ql/src/test/queries/clientpositive/insert_orig_table.q
+++ b/ql/src/test/queries/clientpositive/insert_orig_table.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.support.concurrency=true;
 set hive.txn.manager=org.apache.hadoop.hive.ql.lockmgr.DbTxnManager;
 set hive.input.format=org.apache.hadoop.hive.ql.io.HiveInputFormat;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/insert_values_orig_table.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/insert_values_orig_table.q b/ql/src/test/queries/clientpositive/insert_values_orig_table.q
index e7ae7c6..db4fc82 100644
--- a/ql/src/test/queries/clientpositive/insert_values_orig_table.q
+++ b/ql/src/test/queries/clientpositive/insert_values_orig_table.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.support.concurrency=true;
 set hive.txn.manager=org.apache.hadoop.hive.ql.lockmgr.DbTxnManager;
 set hive.input.format=org.apache.hadoop.hive.ql.io.HiveInputFormat;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/insert_values_orig_table_use_metadata.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/insert_values_orig_table_use_metadata.q b/ql/src/test/queries/clientpositive/insert_values_orig_table_use_metadata.q
index 5e208c4..49c5b0a 100644
--- a/ql/src/test/queries/clientpositive/insert_values_orig_table_use_metadata.q
+++ b/ql/src/test/queries/clientpositive/insert_values_orig_table_use_metadata.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.support.concurrency=true;
 set hive.txn.manager=org.apache.hadoop.hive.ql.lockmgr.DbTxnManager;
 set hive.input.format=org.apache.hadoop.hive.ql.io.HiveInputFormat;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/merge_dynamic_partition.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/merge_dynamic_partition.q b/ql/src/test/queries/clientpositive/merge_dynamic_partition.q
index fa4d442..f70d1c2 100644
--- a/ql/src/test/queries/clientpositive/merge_dynamic_partition.q
+++ b/ql/src/test/queries/clientpositive/merge_dynamic_partition.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 set hive.exec.dynamic.partition=true;
 set hive.exec.dynamic.partition.mode=nonstrict;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/merge_dynamic_partition2.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/merge_dynamic_partition2.q b/ql/src/test/queries/clientpositive/merge_dynamic_partition2.q
index 73a71e6..e61b615 100644
--- a/ql/src/test/queries/clientpositive/merge_dynamic_partition2.q
+++ b/ql/src/test/queries/clientpositive/merge_dynamic_partition2.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.exec.dynamic.partition=true;
 set hive.exec.dynamic.partition.mode=nonstrict;
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/merge_dynamic_partition3.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/merge_dynamic_partition3.q b/ql/src/test/queries/clientpositive/merge_dynamic_partition3.q
index 79ae2b9..8caf933 100644
--- a/ql/src/test/queries/clientpositive/merge_dynamic_partition3.q
+++ b/ql/src/test/queries/clientpositive/merge_dynamic_partition3.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.exec.dynamic.partition=true;
 set hive.exec.dynamic.partition.mode=nonstrict;
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/merge_dynamic_partition4.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/merge_dynamic_partition4.q b/ql/src/test/queries/clientpositive/merge_dynamic_partition4.q
index 33388c6..9be7f16 100644
--- a/ql/src/test/queries/clientpositive/merge_dynamic_partition4.q
+++ b/ql/src/test/queries/clientpositive/merge_dynamic_partition4.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- this test verifies that the block merge task that can follow a query to generate dynamic
 -- partitions does not produce incorrect results by dropping partitions

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/merge_dynamic_partition5.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/merge_dynamic_partition5.q b/ql/src/test/queries/clientpositive/merge_dynamic_partition5.q
index 9a35101..89a8849 100644
--- a/ql/src/test/queries/clientpositive/merge_dynamic_partition5.q
+++ b/ql/src/test/queries/clientpositive/merge_dynamic_partition5.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- this is to test the case where some dynamic partitions are merged and some are moved
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/mergejoin.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/mergejoin.q b/ql/src/test/queries/clientpositive/mergejoin.q
index fa53a76..eecd105 100644
--- a/ql/src/test/queries/clientpositive/mergejoin.q
+++ b/ql/src/test/queries/clientpositive/mergejoin.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 set hive.explain.user=false;
 set hive.join.emit.interval=100000;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/smb_mapjoin_1.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/smb_mapjoin_1.q b/ql/src/test/queries/clientpositive/smb_mapjoin_1.q
index 4f913e7..6051e4e 100644
--- a/ql/src/test/queries/clientpositive/smb_mapjoin_1.q
+++ b/ql/src/test/queries/clientpositive/smb_mapjoin_1.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 
 
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/smb_mapjoin_10.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/smb_mapjoin_10.q b/ql/src/test/queries/clientpositive/smb_mapjoin_10.q
index 1fbe209..cd332c8 100644
--- a/ql/src/test/queries/clientpositive/smb_mapjoin_10.q
+++ b/ql/src/test/queries/clientpositive/smb_mapjoin_10.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 
 create table tmp_smb_bucket_10(userid int, pageid int, postid int, type string) partitioned by (ds string) CLUSTERED BY (userid) SORTED BY (pageid, postid, type, userid) INTO 2 BUCKETS STORED AS RCFILE; 
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/smb_mapjoin_2.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/smb_mapjoin_2.q b/ql/src/test/queries/clientpositive/smb_mapjoin_2.q
index 5e729d9..672cd54 100644
--- a/ql/src/test/queries/clientpositive/smb_mapjoin_2.q
+++ b/ql/src/test/queries/clientpositive/smb_mapjoin_2.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 
 
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/smb_mapjoin_25.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/smb_mapjoin_25.q b/ql/src/test/queries/clientpositive/smb_mapjoin_25.q
index 834d44c..44da19b 100644
--- a/ql/src/test/queries/clientpositive/smb_mapjoin_25.q
+++ b/ql/src/test/queries/clientpositive/smb_mapjoin_25.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/smb_mapjoin_3.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/smb_mapjoin_3.q b/ql/src/test/queries/clientpositive/smb_mapjoin_3.q
index 549eb85..48f6ed2 100644
--- a/ql/src/test/queries/clientpositive/smb_mapjoin_3.q
+++ b/ql/src/test/queries/clientpositive/smb_mapjoin_3.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 -- SORT_QUERY_RESULTS
 
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/smb_mapjoin_4.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/smb_mapjoin_4.q b/ql/src/test/queries/clientpositive/smb_mapjoin_4.q
index e9d28ba..4e3fcae 100644
--- a/ql/src/test/queries/clientpositive/smb_mapjoin_4.q
+++ b/ql/src/test/queries/clientpositive/smb_mapjoin_4.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 
 
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/smb_mapjoin_5.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/smb_mapjoin_5.q b/ql/src/test/queries/clientpositive/smb_mapjoin_5.q
index 5b6eeb8..0decdaf 100644
--- a/ql/src/test/queries/clientpositive/smb_mapjoin_5.q
+++ b/ql/src/test/queries/clientpositive/smb_mapjoin_5.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 
 
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/smb_mapjoin_7.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/smb_mapjoin_7.q b/ql/src/test/queries/clientpositive/smb_mapjoin_7.q
index bd859b7..f0b41a4 100644
--- a/ql/src/test/queries/clientpositive/smb_mapjoin_7.q
+++ b/ql/src/test/queries/clientpositive/smb_mapjoin_7.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 set hive.exec.reducers.max = 1;
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/smb_mapjoin_8.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/smb_mapjoin_8.q b/ql/src/test/queries/clientpositive/smb_mapjoin_8.q
index dc6a35f..d2624bb 100644
--- a/ql/src/test/queries/clientpositive/smb_mapjoin_8.q
+++ b/ql/src/test/queries/clientpositive/smb_mapjoin_8.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.input.format=org.apache.hadoop.hive.ql.io.HiveInputFormat;
 ;
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/stats1.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/stats1.q b/ql/src/test/queries/clientpositive/stats1.q
index e5133c8..a759122 100644
--- a/ql/src/test/queries/clientpositive/stats1.q
+++ b/ql/src/test/queries/clientpositive/stats1.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 set datanucleus.cache.collections=false;
 set hive.stats.autogather=true;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/stats11.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/stats11.q b/ql/src/test/queries/clientpositive/stats11.q
index d037c00..6cf6d54 100644
--- a/ql/src/test/queries/clientpositive/stats11.q
+++ b/ql/src/test/queries/clientpositive/stats11.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set datanucleus.cache.collections=false;
 set hive.stats.autogather=true;
 

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/stats18.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/stats18.q b/ql/src/test/queries/clientpositive/stats18.q
index e773cd7..6652e0e 100644
--- a/ql/src/test/queries/clientpositive/stats18.q
+++ b/ql/src/test/queries/clientpositive/stats18.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set datanucleus.cache.collections=false;
 set hive.stats.autogather=true;
 set hive.merge.mapfiles=false;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/tez_fsstat.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/tez_fsstat.q b/ql/src/test/queries/clientpositive/tez_fsstat.q
index 4aecd71..22e46fe 100644
--- a/ql/src/test/queries/clientpositive/tez_fsstat.q
+++ b/ql/src/test/queries/clientpositive/tez_fsstat.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 CREATE TABLE tab_part (key int, value string) PARTITIONED BY(ds STRING) CLUSTERED BY (key) INTO 4 BUCKETS STORED AS TEXTFILE;
 CREATE TABLE t1 (key int, value string) partitioned by (ds string) CLUSTERED BY (key) INTO 4 BUCKETS STORED AS TEXTFILE;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/tez_smb_1.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/tez_smb_1.q b/ql/src/test/queries/clientpositive/tez_smb_1.q
index 089ffe3..6862a9a 100644
--- a/ql/src/test/queries/clientpositive/tez_smb_1.q
+++ b/ql/src/test/queries/clientpositive/tez_smb_1.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 set hive.explain.user=false;
 set hive.auto.convert.join=true;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/tez_smb_empty.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/tez_smb_empty.q b/ql/src/test/queries/clientpositive/tez_smb_empty.q
index 4661ada..8b3211d 100644
--- a/ql/src/test/queries/clientpositive/tez_smb_empty.q
+++ b/ql/src/test/queries/clientpositive/tez_smb_empty.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 set hive.explain.user=false;
 set hive.mapjoin.hybridgrace.hashtable=false;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/tez_smb_main.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/tez_smb_main.q b/ql/src/test/queries/clientpositive/tez_smb_main.q
index 9ed5959..ee24691 100644
--- a/ql/src/test/queries/clientpositive/tez_smb_main.q
+++ b/ql/src/test/queries/clientpositive/tez_smb_main.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 set hive.explain.user=false;
 set hive.join.emit.interval=2;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/udaf_percentile_approx_20.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/udaf_percentile_approx_20.q b/ql/src/test/queries/clientpositive/udaf_percentile_approx_20.q
index 7aae8ae..30052eb 100644
--- a/ql/src/test/queries/clientpositive/udaf_percentile_approx_20.q
+++ b/ql/src/test/queries/clientpositive/udaf_percentile_approx_20.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 -- INCLUDE_HADOOP_MAJOR_VERSIONS( 0.20S)
 
 CREATE TABLE bucket (key double, value string) CLUSTERED BY (key) SORTED BY (key DESC)  INTO 4 BUCKETS STORED AS TEXTFILE;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/udaf_percentile_approx_23.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/udaf_percentile_approx_23.q b/ql/src/test/queries/clientpositive/udaf_percentile_approx_23.q
index aa4a4ce..80ea489 100644
--- a/ql/src/test/queries/clientpositive/udaf_percentile_approx_23.q
+++ b/ql/src/test/queries/clientpositive/udaf_percentile_approx_23.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 -- INCLUDE_HADOOP_MAJOR_VERSIONS(0.23)
 -- 0.23 changed input order of data in reducer task, which affects result of percentile_approx

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/varchar_1.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/varchar_1.q b/ql/src/test/queries/clientpositive/varchar_1.q
index efaf3e5..8f397fb 100644
--- a/ql/src/test/queries/clientpositive/varchar_1.q
+++ b/ql/src/test/queries/clientpositive/varchar_1.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 set hive.mapred.mode=nonstrict;
 drop table varchar1;
 drop table varchar1_1;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/queries/clientpositive/varchar_serde.q
----------------------------------------------------------------------
diff --git a/ql/src/test/queries/clientpositive/varchar_serde.q b/ql/src/test/queries/clientpositive/varchar_serde.q
index ea2a022..7b3d7a9 100644
--- a/ql/src/test/queries/clientpositive/varchar_serde.q
+++ b/ql/src/test/queries/clientpositive/varchar_serde.q
@@ -1,3 +1,5 @@
+set hive.strict.checks.bucketing=false;
+
 drop table if exists varchar_serde_regex;
 drop table if exists varchar_serde_lb;
 drop table if exists varchar_serde_ls;

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/results/clientnegative/alter_view_failure6.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientnegative/alter_view_failure6.q.out b/ql/src/test/results/clientnegative/alter_view_failure6.q.out
index 70d7622..78416ad 100644
--- a/ql/src/test/results/clientnegative/alter_view_failure6.q.out
+++ b/ql/src/test/results/clientnegative/alter_view_failure6.q.out
@@ -18,5 +18,5 @@ POSTHOOK: type: CREATEVIEW
 POSTHOOK: Input: default@srcpart
 POSTHOOK: Output: database:default
 POSTHOOK: Output: default@xxx7
-FAILED: SemanticException Queries against partitioned tables without a partition filter are disabled for safety reasons. If you know what you are doing, please make sure that hive.strict.checks.large.query is set to false and that hive.mapred.mode is not set to 'strict' to enable them. No partition predicate for Alias "default.xxx7:srcpart" Table "srcpart"
+FAILED: SemanticException Queries against partitioned tables without a partition filter are disabled for safety reasons. If you know what you are doing, please sethive.strict.checks.large.query to false and that hive.mapred.mode is not set to 'strict' to proceed. Note that if you may get errors or incorrect results if you make a mistake while using some of the unsafe features. No partition predicate for Alias "default.xxx7:srcpart" Table "srcpart"
 FAILED: SemanticException [Error 10056]: The query does not reference any valid partition. To run this query, set hive.mapred.mode=nonstrict

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/results/clientnegative/compare_double_bigint.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientnegative/compare_double_bigint.q.out b/ql/src/test/results/clientnegative/compare_double_bigint.q.out
index 10a5667..26a64fc 100644
--- a/ql/src/test/results/clientnegative/compare_double_bigint.q.out
+++ b/ql/src/test/results/clientnegative/compare_double_bigint.q.out
@@ -1 +1 @@
-FAILED: SemanticException Line 0:-1 Wrong arguments '1.0': Unsafe compares between different types are disabled for safety reasons. If you know what you are doing, please make sure that hive.strict.checks.type.safety is set to false and that hive.mapred.mode is not set to 'strict' to enable them.
+FAILED: SemanticException Line 0:-1 Wrong arguments '1.0': Unsafe compares between different types are disabled for safety reasons. If you know what you are doing, please sethive.strict.checks.type.safety to false and that hive.mapred.mode is not set to 'strict' to proceed. Note that if you may get errors or incorrect results if you make a mistake while using some of the unsafe features.

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/results/clientnegative/compare_string_bigint.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientnegative/compare_string_bigint.q.out b/ql/src/test/results/clientnegative/compare_string_bigint.q.out
index c8eb290..d80b314 100644
--- a/ql/src/test/results/clientnegative/compare_string_bigint.q.out
+++ b/ql/src/test/results/clientnegative/compare_string_bigint.q.out
@@ -1 +1 @@
-FAILED: SemanticException Line 0:-1 Wrong arguments ''1'': Unsafe compares between different types are disabled for safety reasons. If you know what you are doing, please make sure that hive.strict.checks.type.safety is set to false and that hive.mapred.mode is not set to 'strict' to enable them.
+FAILED: SemanticException Line 0:-1 Wrong arguments ''1'': Unsafe compares between different types are disabled for safety reasons. If you know what you are doing, please sethive.strict.checks.type.safety to false and that hive.mapred.mode is not set to 'strict' to proceed. Note that if you may get errors or incorrect results if you make a mistake while using some of the unsafe features.

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/results/clientnegative/input4.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientnegative/input4.q.out b/ql/src/test/results/clientnegative/input4.q.out
index 887865d..0e04710 100644
--- a/ql/src/test/results/clientnegative/input4.q.out
+++ b/ql/src/test/results/clientnegative/input4.q.out
@@ -1 +1 @@
-FAILED: SemanticException Cartesian products are disabled for safety reasons. If you know what you are doing, please make sure that hive.strict.checks.cartesian.product is set to false and that hive.mapred.mode is not set to 'strict' to enable them.
+FAILED: SemanticException Cartesian products are disabled for safety reasons. If you know what you are doing, please sethive.strict.checks.cartesian.product to false and that hive.mapred.mode is not set to 'strict' to proceed. Note that if you may get errors or incorrect results if you make a mistake while using some of the unsafe features.

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/results/clientnegative/input_part0_neg.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientnegative/input_part0_neg.q.out b/ql/src/test/results/clientnegative/input_part0_neg.q.out
index 3abe4b7..8c5761b 100644
--- a/ql/src/test/results/clientnegative/input_part0_neg.q.out
+++ b/ql/src/test/results/clientnegative/input_part0_neg.q.out
@@ -1 +1 @@
-FAILED: SemanticException Queries against partitioned tables without a partition filter are disabled for safety reasons. If you know what you are doing, please make sure that hive.strict.checks.large.query is set to false and that hive.mapred.mode is not set to 'strict' to enable them. No partition predicate for Alias "x" Table "srcpart"
+FAILED: SemanticException Queries against partitioned tables without a partition filter are disabled for safety reasons. If you know what you are doing, please sethive.strict.checks.large.query to false and that hive.mapred.mode is not set to 'strict' to proceed. Note that if you may get errors or incorrect results if you make a mistake while using some of the unsafe features. No partition predicate for Alias "x" Table "srcpart"

http://git-wip-us.apache.org/repos/asf/hive/blob/0a6fc638/ql/src/test/results/clientnegative/strict_join.q.out
----------------------------------------------------------------------
diff --git a/ql/src/test/results/clientnegative/strict_join.q.out b/ql/src/test/results/clientnegative/strict_join.q.out
index 887865d..0e04710 100644
--- a/ql/src/test/results/clientnegative/strict_join.q.out
+++ b/ql/src/test/results/clientnegative/strict_join.q.out
@@ -1 +1 @@
-FAILED: SemanticException Cartesian products are disabled for safety reasons. If you know what you are doing, please make sure that hive.strict.checks.cartesian.product is set to false and that hive.mapred.mode is not set to 'strict' to enable them.
+FAILED: SemanticException Cartesian products are disabled for safety reasons. If you know what you are doing, please sethive.strict.checks.cartesian.product to false and that hive.mapred.mode is not set to 'strict' to proceed. Note that if you may get errors or incorrect results if you make a mistake while using some of the unsafe features.