PageRenderTime 12ms CodeModel.GetById 7ms app.highlight 1ms RepoModel.GetById 2ms app.codeStats 0ms

/tags/release-0.0.0-rc0/hive/external/ql/src/test/queries/clientpositive/ppd_gby2.q

#
text | 14 lines | 12 code | 2 blank | 0 comment | 0 complexity | 918e435633f699bbbe7cad9dcb328997 MD5 | raw file
 1set hive.optimize.ppd=true;
 2
 3EXPLAIN
 4SELECT max(src1.c1), src1.c2 
 5FROM
 6(SELECT src.value AS c1, count(src.key) AS c2 FROM src WHERE src.value > 'val_10' GROUP BY src.value) src1
 7WHERE src1.c1 > 'val_200' AND (src1.c2 > 30 OR src1.c1 < 'val_400')
 8GROUP BY src1.c2; 
 9
10SELECT max(src1.c1), src1.c2 
11FROM
12(SELECT src.value AS c1, count(src.key) AS c2 FROM src WHERE src.value > 'val_10' GROUP BY src.value) src1
13WHERE src1.c1 > 'val_200' AND (src1.c2 > 30 OR src1.c1 < 'val_400')
14GROUP BY src1.c2;