diff --git a/itests/src/test/resources/testconfiguration.properties b/itests/src/test/resources/testconfiguration.properties index 19a90b90a2..6497b92c9d 100644 --- a/itests/src/test/resources/testconfiguration.properties +++ b/itests/src/test/resources/testconfiguration.properties @@ -31,10 +31,10 @@ minitez.query.files.shared=delete_orig_table.q,\ # specific to tez and cannot be added to minillap. minitez.query.files=acid_vectorization_original_tez.q,\ explainuser_3.q,\ - explainanalyze_1.q,\ - explainanalyze_3.q,\ - explainanalyze_4.q,\ - explainanalyze_5.q,\ + explainprofile_1.q,\ + explainprofile_3.q,\ + explainprofile_4.q,\ + explainprofile_5.q,\ hybridgrace_hashjoin_1.q,\ hybridgrace_hashjoin_2.q,\ multi_count_distinct.q,\ @@ -562,7 +562,7 @@ minillaplocal.query.files=\ estimate_pkfk_filtered_fk.q,\ estimate_pkfk_push.q,\ exchgpartition2lel.q,\ - explainanalyze_2.q,\ + explainprofile_2.q,\ explainuser_1.q,\ explainuser_4.q,\ external_jdbc_auth.q,\ diff --git a/parser/src/java/org/apache/hadoop/hive/ql/parse/HiveLexer.g b/parser/src/java/org/apache/hadoop/hive/ql/parse/HiveLexer.g index 23f74ba05e..4e7f7b7e9e 100644 --- a/parser/src/java/org/apache/hadoop/hive/ql/parse/HiveLexer.g +++ b/parser/src/java/org/apache/hadoop/hive/ql/parse/HiveLexer.g @@ -394,6 +394,7 @@ KW_AST: 'AST'; KW_COST: 'COST'; KW_JOINCOST: 'JOINCOST'; KW_WITHIN: 'WITHIN'; +KW_PROFILE: 'PROFILE'; // Operators // NOTE: if you add a new function/operator, add it to sysFuncNames so that describe function _FUNC_ will work. diff --git a/parser/src/java/org/apache/hadoop/hive/ql/parse/HiveParser.g b/parser/src/java/org/apache/hadoop/hive/ql/parse/HiveParser.g index 2b865f3cf7..7652b3be46 100644 --- a/parser/src/java/org/apache/hadoop/hive/ql/parse/HiveParser.g +++ b/parser/src/java/org/apache/hadoop/hive/ql/parse/HiveParser.g @@ -842,7 +842,7 @@ explainOption | KW_CBO (KW_COST | KW_JOINCOST)? | KW_LOGICAL | KW_AUTHORIZATION - | KW_ANALYZE + | KW_PROFILE | KW_REOPTIMIZATION | KW_LOCKS | KW_AST diff --git a/ql/src/java/org/apache/hadoop/hive/ql/Context.java b/ql/src/java/org/apache/hadoop/hive/ql/Context.java index d618ef96f3..d47647b579 100644 --- a/ql/src/java/org/apache/hadoop/hive/ql/Context.java +++ b/ql/src/java/org/apache/hadoop/hive/ql/Context.java @@ -412,7 +412,7 @@ public boolean getExplainLogical() { return explainConfig != null && explainConfig.isLogical(); } - public AnalyzeState getExplainAnalyze() { + public AnalyzeState getExplainProfile() { if (explainConfig != null) { return explainConfig.getAnalyze(); } @@ -953,7 +953,7 @@ private static boolean strEquals(String str1, String str2) { * the stream being used */ public void setTokenRewriteStream(TokenRewriteStream tokenRewriteStream) { - assert (this.tokenRewriteStream == null || this.getExplainAnalyze() == AnalyzeState.RUNNING); + assert (this.tokenRewriteStream == null || this.getExplainProfile() == AnalyzeState.RUNNING); this.tokenRewriteStream = tokenRewriteStream; } diff --git a/ql/src/java/org/apache/hadoop/hive/ql/Driver.java b/ql/src/java/org/apache/hadoop/hive/ql/Driver.java index 517b0cc443..60d2ddd4b7 100644 --- a/ql/src/java/org/apache/hadoop/hive/ql/Driver.java +++ b/ql/src/java/org/apache/hadoop/hive/ql/Driver.java @@ -242,7 +242,7 @@ public void run() { } private void prepareContext() throws CommandProcessorException { - if (context != null && context.getExplainAnalyze() != AnalyzeState.RUNNING) { + if (context != null && context.getExplainProfile() != AnalyzeState.RUNNING) { // close the existing ctx etc before compiling a new query, but does not destroy driver closeInProcess(false); } diff --git a/ql/src/java/org/apache/hadoop/hive/ql/ddl/DDLTask.java b/ql/src/java/org/apache/hadoop/hive/ql/ddl/DDLTask.java index 3e4496471f..1760467036 100644 --- a/ql/src/java/org/apache/hadoop/hive/ql/ddl/DDLTask.java +++ b/ql/src/java/org/apache/hadoop/hive/ql/ddl/DDLTask.java @@ -63,7 +63,7 @@ public boolean requireLock() { @Override public int execute() { - if (context.getExplainAnalyze() == AnalyzeState.RUNNING) { + if (context.getExplainProfile() == AnalyzeState.RUNNING) { return 0; } diff --git a/ql/src/java/org/apache/hadoop/hive/ql/ddl/view/materialized/update/MaterializedViewUpdateOperation.java b/ql/src/java/org/apache/hadoop/hive/ql/ddl/view/materialized/update/MaterializedViewUpdateOperation.java index 5c9ad4cbad..99dd3f4991 100644 --- a/ql/src/java/org/apache/hadoop/hive/ql/ddl/view/materialized/update/MaterializedViewUpdateOperation.java +++ b/ql/src/java/org/apache/hadoop/hive/ql/ddl/view/materialized/update/MaterializedViewUpdateOperation.java @@ -40,7 +40,7 @@ public MaterializedViewUpdateOperation(DDLOperationContext context, Materialized @Override public int execute() throws HiveException { - if (context.getContext().getExplainAnalyze() == AnalyzeState.RUNNING) { + if (context.getContext().getExplainProfile() == AnalyzeState.RUNNING) { return 0; } diff --git a/ql/src/java/org/apache/hadoop/hive/ql/exec/MoveTask.java b/ql/src/java/org/apache/hadoop/hive/ql/exec/MoveTask.java index 51de87f2fd..59e88a08bb 100644 --- a/ql/src/java/org/apache/hadoop/hive/ql/exec/MoveTask.java +++ b/ql/src/java/org/apache/hadoop/hive/ql/exec/MoveTask.java @@ -307,7 +307,7 @@ public int execute() { } try { - if (context.getExplainAnalyze() == AnalyzeState.RUNNING) { + if (context.getExplainProfile() == AnalyzeState.RUNNING) { return 0; } Hive db = getHive(); diff --git a/ql/src/java/org/apache/hadoop/hive/ql/exec/StatsTask.java b/ql/src/java/org/apache/hadoop/hive/ql/exec/StatsTask.java index 393d21dd0c..a3fa0efbae 100644 --- a/ql/src/java/org/apache/hadoop/hive/ql/exec/StatsTask.java +++ b/ql/src/java/org/apache/hadoop/hive/ql/exec/StatsTask.java @@ -86,7 +86,7 @@ public void initialize(QueryState queryState, QueryPlan queryPlan, TaskQueue tas @Override public int execute() { - if (context.getExplainAnalyze() == AnalyzeState.RUNNING) { + if (context.getExplainProfile() == AnalyzeState.RUNNING) { return 0; } if (work.isAggregating() && work.isFooterScan()) { diff --git a/ql/src/java/org/apache/hadoop/hive/ql/optimizer/physical/AnnotateRunTimeStatsOptimizer.java b/ql/src/java/org/apache/hadoop/hive/ql/optimizer/physical/AnnotateRunTimeStatsOptimizer.java index 21969f62ca..4b0eb0c166 100644 --- a/ql/src/java/org/apache/hadoop/hive/ql/optimizer/physical/AnnotateRunTimeStatsOptimizer.java +++ b/ql/src/java/org/apache/hadoop/hive/ql/optimizer/physical/AnnotateRunTimeStatsOptimizer.java @@ -94,9 +94,9 @@ public Object dispatch(Node nd, Stack stack, Object... nodeOutputs) public static void setOrAnnotateStats(Set> ops, ParseContext pctx) throws SemanticException { for (Operator op : ops) { - if (pctx.getContext().getExplainAnalyze() == AnalyzeState.RUNNING) { + if (pctx.getContext().getExplainProfile() == AnalyzeState.RUNNING) { setRuntimeStatsDir(op, pctx); - } else if (pctx.getContext().getExplainAnalyze() == AnalyzeState.ANALYZING) { + } else if (pctx.getContext().getExplainProfile() == AnalyzeState.ANALYZING) { annotateRuntimeStats(op, pctx); } else { throw new SemanticException("Unexpected stats in AnnotateWithRunTimeStatistics."); diff --git a/ql/src/java/org/apache/hadoop/hive/ql/optimizer/physical/PhysicalOptimizer.java b/ql/src/java/org/apache/hadoop/hive/ql/optimizer/physical/PhysicalOptimizer.java index 8903eb7381..c29b82788b 100644 --- a/ql/src/java/org/apache/hadoop/hive/ql/optimizer/physical/PhysicalOptimizer.java +++ b/ql/src/java/org/apache/hadoop/hive/ql/optimizer/physical/PhysicalOptimizer.java @@ -95,7 +95,7 @@ private void initialize(HiveConf hiveConf) { resolvers.add(new StageIDsRearranger()); } - if (pctx.getContext().getExplainAnalyze() != null) { + if (pctx.getContext().getExplainProfile() != null) { resolvers.add(new AnnotateRunTimeStatsOptimizer()); } } diff --git a/ql/src/java/org/apache/hadoop/hive/ql/parse/ExplainSemanticAnalyzer.java b/ql/src/java/org/apache/hadoop/hive/ql/parse/ExplainSemanticAnalyzer.java index df6e5e5aba..e80250d9b5 100644 --- a/ql/src/java/org/apache/hadoop/hive/ql/parse/ExplainSemanticAnalyzer.java +++ b/ql/src/java/org/apache/hadoop/hive/ql/parse/ExplainSemanticAnalyzer.java @@ -84,7 +84,7 @@ public void analyzeInternal(ASTNode ast) throws SemanticException { config.setLogical(true); } else if (explainOptions == HiveParser.KW_AUTHORIZATION) { config.setAuthorize(true); - } else if (explainOptions == HiveParser.KW_ANALYZE) { + } else if (explainOptions == HiveParser.KW_PROFILE) { config.setAnalyze(AnalyzeState.RUNNING); config.setExplainRootPath(ctx.getMRTmpPath()); } else if (explainOptions == HiveParser.KW_VECTORIZATION) { diff --git a/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java b/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java index c87f2d2292..a52c89893b 100644 --- a/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java +++ b/ql/src/java/org/apache/hadoop/hive/ql/parse/SemanticAnalyzer.java @@ -12665,7 +12665,7 @@ void analyzeInternal(ASTNode ast, Supplier pcf) throws SemanticE // 5. Take care of view creation if (createVwDesc != null) { - if (ctx.getExplainAnalyze() == AnalyzeState.RUNNING) { + if (ctx.getExplainProfile() == AnalyzeState.RUNNING) { return; } @@ -15270,7 +15270,7 @@ private boolean queryTypeCanUseCache() { } // HIVE-19096 - disable for explain analyze - return ctx.getExplainAnalyze() == null; + return ctx.getExplainProfile() == null; } private boolean needsTransform() { diff --git a/ql/src/java/org/apache/hadoop/hive/ql/parse/TezCompiler.java b/ql/src/java/org/apache/hadoop/hive/ql/parse/TezCompiler.java index caab0564f2..8d74f3c426 100644 --- a/ql/src/java/org/apache/hadoop/hive/ql/parse/TezCompiler.java +++ b/ql/src/java/org/apache/hadoop/hive/ql/parse/TezCompiler.java @@ -807,7 +807,7 @@ protected void optimizeTaskPlan(List> rootTasks, ParseContext pCtx, // table scans or filters, you have to invoke it before this one. physicalCtx = new SerializeFilter().resolve(physicalCtx); - if (physicalCtx.getContext().getExplainAnalyze() != null) { + if (physicalCtx.getContext().getExplainProfile() != null) { new AnnotateRunTimeStatsOptimizer().resolve(physicalCtx); } diff --git a/ql/src/java/org/apache/hadoop/hive/ql/parse/spark/SparkCompiler.java b/ql/src/java/org/apache/hadoop/hive/ql/parse/spark/SparkCompiler.java index 09fa14530e..ddc2976e78 100644 --- a/ql/src/java/org/apache/hadoop/hive/ql/parse/spark/SparkCompiler.java +++ b/ql/src/java/org/apache/hadoop/hive/ql/parse/spark/SparkCompiler.java @@ -629,7 +629,7 @@ protected void optimizeTaskPlan(List> rootTasks, ParseContext pCtx, LOG.debug("Skipping combine equivalent work optimization"); } - if (physicalCtx.getContext().getExplainAnalyze() != null) { + if (physicalCtx.getContext().getExplainProfile() != null) { new AnnotateRunTimeStatsOptimizer().resolve(physicalCtx); } diff --git a/ql/src/test/queries/clientpositive/estimate_pkfk_filtered_fk.q b/ql/src/test/queries/clientpositive/estimate_pkfk_filtered_fk.q index 70b7e79642..8f9deb1f0c 100644 --- a/ql/src/test/queries/clientpositive/estimate_pkfk_filtered_fk.q +++ b/ql/src/test/queries/clientpositive/estimate_pkfk_filtered_fk.q @@ -8,7 +8,7 @@ set hive.explain.user=true; --set hive.semantic.analyzer.hook=org.apache.hadoop.hive.ql.hooks.AccurateEstimatesCheckerHook; -explain analyze +explain profile select s.id from @@ -26,7 +26,7 @@ where -- but this simpler case can be asserted set hive.semantic.analyzer.hook=org.apache.hadoop.hive.ql.hooks.AccurateEstimatesCheckerHook; -explain analyze +explain profile select s.id from diff --git a/ql/src/test/queries/clientpositive/estimate_pkfk_fknulls.q b/ql/src/test/queries/clientpositive/estimate_pkfk_fknulls.q index bb547fc06f..50aee5727a 100644 --- a/ql/src/test/queries/clientpositive/estimate_pkfk_fknulls.q +++ b/ql/src/test/queries/clientpositive/estimate_pkfk_fknulls.q @@ -28,7 +28,7 @@ analyze table sr0 compute statistics for columns; desc formatted sr0 sr_reason_sk; -explain analyze select 1 +explain profile select 1 from default.sr0 store_returns , default.rx0 reason where sr_reason_sk = r_reason_sk and r_reason_id = 'AAAAAAAAAAAAAAAA'; diff --git a/ql/src/test/queries/clientpositive/estimate_pkfk_nocond.q b/ql/src/test/queries/clientpositive/estimate_pkfk_nocond.q index 61a4a06dc9..b61c2a1612 100644 --- a/ql/src/test/queries/clientpositive/estimate_pkfk_nocond.q +++ b/ql/src/test/queries/clientpositive/estimate_pkfk_nocond.q @@ -6,7 +6,7 @@ set hive.explain.user=true; set hive.semantic.analyzer.hook=org.apache.hadoop.hive.ql.hooks.AccurateEstimatesCheckerHook; -explain analyze +explain profile select s.id from diff --git a/ql/src/test/queries/clientpositive/estimate_pkfk_push.q b/ql/src/test/queries/clientpositive/estimate_pkfk_push.q index 270c7540d4..4c694fc37d 100644 --- a/ql/src/test/queries/clientpositive/estimate_pkfk_push.q +++ b/ql/src/test/queries/clientpositive/estimate_pkfk_push.q @@ -7,7 +7,7 @@ source ${system:hive.root}/data/files/starships.sql; set hive.explain.user=true; set hive.semantic.analyzer.hook=org.apache.hadoop.hive.ql.hooks.AccurateEstimatesCheckerHook; -explain analyze +explain profile select s.id from diff --git a/ql/src/test/queries/clientpositive/explain_outputs.q b/ql/src/test/queries/clientpositive/explain_outputs.q index d42847db35..f82a8697e2 100644 --- a/ql/src/test/queries/clientpositive/explain_outputs.q +++ b/ql/src/test/queries/clientpositive/explain_outputs.q @@ -8,7 +8,7 @@ insert into t2_n14 values (1),(2),(3),(4),(5); explain select sum(t1_n22.id) from t1_n22 join t2_n14 on (t1_n22.id=t2_n14.id); -explain analyze +explain profile select sum(t1_n22.id) from t1_n22 join t2_n14 on (t1_n22.id=t2_n14.id); explain reoptimization diff --git a/ql/src/test/queries/clientpositive/explainanalyze_1.q b/ql/src/test/queries/clientpositive/explainprofile_1.q similarity index 57% rename from ql/src/test/queries/clientpositive/explainanalyze_1.q rename to ql/src/test/queries/clientpositive/explainprofile_1.q index 9043826313..34ece3fadf 100644 --- a/ql/src/test/queries/clientpositive/explainanalyze_1.q +++ b/ql/src/test/queries/clientpositive/explainprofile_1.q @@ -3,45 +3,45 @@ SET hive.vectorized.execution.enabled=false; set hive.map.aggr=false; set hive.mapred.mode=nonstrict; -explain analyze select * from src a union all select * from src b limit 10; +explain profile select * from src a union all select * from src b limit 10; -explain analyze select key from src; +explain profile select key from src; -explain analyze create table t_n28 as select key from src; +explain profile create table t_n28 as select key from src; create table t_n28 as select key from src; -explain analyze insert overwrite table t_n28 select key from src; +explain profile insert overwrite table t_n28 select key from src; -explain analyze select key from src limit 10; +explain profile select key from src limit 10; -explain analyze select key from src where value < 10; +explain profile select key from src where value < 10; -explain analyze select key from src where key < 10; +explain profile select key from src where key < 10; select count(*) from (select key from src where key < 10)subq; -explain analyze select key, count(key) from src group by key; +explain profile select key, count(key) from src group by key; select count(*) from (select key, count(key) from src group by key)subq; -explain analyze select count(*) from src a join src b on a.key = b.value where a.key > 0; +explain profile select count(*) from src a join src b on a.key = b.value where a.key > 0; -explain analyze select count(*) from src a join src b on a.key = b.key where a.key > 0; +explain profile select count(*) from src a join src b on a.key = b.key where a.key > 0; select count(*) from src a join src b on a.key = b.key where a.key > 0; -explain analyze select * from src a union all select * from src b; +explain profile select * from src a union all select * from src b; select count(*) from (select * from src a union all select * from src b)subq; set hive.auto.convert.join=true; set hive.auto.convert.join.noconditionaltask=true; set hive.auto.convert.join.noconditionaltask.size=10000; -EXPLAIN analyze +explain profile SELECT x.key, y.value FROM src x JOIN src y ON (x.key = y.key); set hive.entity.capture.transform=true; -explain analyze +explain profile SELECT TRANSFORM(a.key, a.value) USING 'cat' AS (tkey, tvalue) FROM src a join src b diff --git a/ql/src/test/queries/clientpositive/explainanalyze_2.q b/ql/src/test/queries/clientpositive/explainprofile_2.q similarity index 96% rename from ql/src/test/queries/clientpositive/explainanalyze_2.q rename to ql/src/test/queries/clientpositive/explainprofile_2.q index 7e48a8a2b8..38d5c9e1c9 100644 --- a/ql/src/test/queries/clientpositive/explainanalyze_2.q +++ b/ql/src/test/queries/clientpositive/explainprofile_2.q @@ -7,7 +7,7 @@ set hive.map.aggr=false; set hive.strict.checks.bucketing=false; set hive.explain.user=true; -explain analyze +explain profile SELECT x.key, z.value, y.value FROM src1 x JOIN src y ON (x.key = y.key) JOIN (select * from src1 union select * from src)z ON (x.value = z.value) @@ -16,7 +16,7 @@ SELECT x.key, z.value, y.value FROM src1 x JOIN src y ON (x.key = y.key) JOIN (select * from src1 union select * from src)z ON (x.value = z.value); -explain analyze +explain profile SELECT x.key, y.value FROM src1 x JOIN src y ON (x.key = y.key) JOIN (select * from src1 union select * from src)z ON (x.value = z.value) @@ -66,25 +66,25 @@ set hive.auto.convert.sortmerge.join = true; set hive.auto.convert.join.noconditionaltask.size=500; -explain analyze +explain profile select s1.key as key, s1.value as value from tab_n6 s1 join tab_n6 s3 on s1.key=s3.key; -explain analyze +explain profile select s1.key as key, s1.value as value from tab_n6 s1 join tab_n6 s3 on s1.key=s3.key join tab_n6 s2 on s1.value=s2.value; -explain analyze +explain profile select s1.key as key, s1.value as value from tab_n6 s1 join tab2_n3 s3 on s1.key=s3.key; -explain analyze +explain profile select s1.key as key, s1.value as value from tab_n6 s1 join tab2_n3 s3 on s1.key=s3.key join tab2_n3 s2 on s1.value=s2.value; -explain analyze +explain profile select count(*) from (select s1.key as key, s1.value as value from tab_n6 s1 join tab_n6 s3 on s1.key=s3.key UNION ALL select s2.key as key, s2.value as value from tab_n6 s2 ) a_n14 join tab_part_n7 b_n10 on (a_n14.key = b_n10.key); -explain analyze +explain profile select count(*) from (select s1.key as key, s1.value as value from tab_n6 s1 join tab_n6 s3 on s1.key=s3.key join tab_n6 s2 on s1.value=s2.value UNION ALL select s2.key as key, s2.value as value from tab_n6 s2 @@ -94,7 +94,7 @@ CREATE TABLE a_n14(key STRING, value STRING) STORED AS TEXTFILE; CREATE TABLE b_n10(key STRING, value STRING) STORED AS TEXTFILE; CREATE TABLE c_n3(key STRING, value STRING) STORED AS TEXTFILE; -explain analyze +explain profile from ( SELECT x.key, y.value @@ -113,7 +113,7 @@ INSERT OVERWRITE TABLE a_n14 SELECT tmp.key, tmp.value INSERT OVERWRITE TABLE b_n10 SELECT tmp.key, tmp.value INSERT OVERWRITE TABLE c_n3 SELECT tmp.key, tmp.value; -explain analyze +explain profile FROM ( SELECT x.key as key, y.value as value from src1 x JOIN src y ON (x.key = y.key) @@ -133,17 +133,17 @@ INSERT OVERWRITE TABLE c_n3 SELECT tmp.key, tmp.value; CREATE TABLE DEST1_n105(key STRING, value STRING) STORED AS TEXTFILE; CREATE TABLE DEST2_n29(key STRING, val1 STRING, val2 STRING) STORED AS TEXTFILE; -explain analyze +explain profile FROM (select 'tst1' as key, cast(count(1) as string) as value from src s1 UNION DISTINCT select s2.key as key, s2.value as value from src s2) unionsrc_n3 INSERT OVERWRITE TABLE DEST1_n105 SELECT unionsrc_n3.key, COUNT(DISTINCT SUBSTR(unionsrc_n3.value,5)) GROUP BY unionsrc_n3.key INSERT OVERWRITE TABLE DEST2_n29 SELECT unionsrc_n3.key, unionsrc_n3.value, COUNT(DISTINCT SUBSTR(unionsrc_n3.value,5)) GROUP BY unionsrc_n3.key, unionsrc_n3.value; -explain analyze FROM UNIQUEJOIN PRESERVE src a_n14 (a_n14.key), PRESERVE src1 b_n10 (b_n10.key), PRESERVE srcpart c_n3 (c_n3.key) SELECT a_n14.key, b_n10.key, c_n3.key; +explain profile FROM UNIQUEJOIN PRESERVE src a_n14 (a_n14.key), PRESERVE src1 b_n10 (b_n10.key), PRESERVE srcpart c_n3 (c_n3.key) SELECT a_n14.key, b_n10.key, c_n3.key; -explain analyze +explain profile FROM ( select key, value from ( select 'tst1' as key, cast(count(1) as string) as value, 'tst1' as value2 from src s1 @@ -156,7 +156,7 @@ INSERT OVERWRITE TABLE DEST1_n105 SELECT unionsrc_n3.key, COUNT(DISTINCT SUBSTR( INSERT OVERWRITE TABLE DEST2_n29 SELECT unionsrc_n3.key, unionsrc_n3.value, COUNT(DISTINCT SUBSTR(unionsrc_n3.value,5)) GROUP BY unionsrc_n3.key, unionsrc_n3.value; -explain analyze +explain profile FROM ( select 'tst1' as key, cast(count(1) as string) as value, 'tst1' as value2 from src s1 UNION all diff --git a/ql/src/test/queries/clientpositive/explainanalyze_3.q b/ql/src/test/queries/clientpositive/explainprofile_3.q similarity index 76% rename from ql/src/test/queries/clientpositive/explainanalyze_3.q rename to ql/src/test/queries/clientpositive/explainprofile_3.q index 72a2161d97..b61d058bc0 100644 --- a/ql/src/test/queries/clientpositive/explainanalyze_3.q +++ b/ql/src/test/queries/clientpositive/explainprofile_3.q @@ -16,32 +16,32 @@ set hive.txn.manager=org.apache.hadoop.hive.ql.lockmgr.DbTxnManager; set hive.vectorized.execution.enabled=true; set hive.llap.io.enabled=false; -explain analyze select key, value +explain profile select key, value FROM srcpart LATERAL VIEW explode(array(1,2,3)) myTable AS myCol; -explain analyze show tables; +explain profile show tables; -explain analyze create database newDB location "/tmp/"; +explain profile create database newDB location "/tmp/"; create database newDB location "/tmp/"; -explain analyze describe database extended newDB; +explain profile describe database extended newDB; describe database extended newDB; -explain analyze use newDB; +explain profile use newDB; use newDB; create table tab_n2 (name string); -explain analyze alter table tab_n2 rename to newName; +explain profile alter table tab_n2 rename to newName; -explain analyze drop table tab_n2; +explain profile drop table tab_n2; drop table tab_n2; -explain analyze use default; +explain profile use default; use default; @@ -51,62 +51,62 @@ drop table src_stats; create table src_stats as select * from src; -explain analyze analyze table src_stats compute statistics; +explain profile analyze table src_stats compute statistics; -explain analyze analyze table src_stats compute statistics for columns; +explain profile analyze table src_stats compute statistics for columns; -explain analyze +explain profile CREATE TEMPORARY MACRO SIGMOID (x DOUBLE) 1.0 / (1.0 + EXP(-x)); CREATE TEMPORARY MACRO SIGMOID (x DOUBLE) 1.0 / (1.0 + EXP(-x)); -explain analyze SELECT SIGMOID(2) FROM src LIMIT 1; -explain analyze DROP TEMPORARY MACRO SIGMOID; +explain profile SELECT SIGMOID(2) FROM src LIMIT 1; +explain profile DROP TEMPORARY MACRO SIGMOID; DROP TEMPORARY MACRO SIGMOID; -explain analyze create table src_autho_test_n4 as select * from src; +explain profile create table src_autho_test_n4 as select * from src; create table src_autho_test_n4 as select * from src; set hive.security.authorization.enabled=true; -explain analyze grant select on table src_autho_test_n4 to user hive_test_user; +explain profile grant select on table src_autho_test_n4 to user hive_test_user; grant select on table src_autho_test_n4 to user hive_test_user; -explain analyze show grant user hive_test_user on table src_autho_test_n4; -explain analyze show grant user hive_test_user on table src_autho_test_n4(key); +explain profile show grant user hive_test_user on table src_autho_test_n4; +explain profile show grant user hive_test_user on table src_autho_test_n4(key); select key from src_autho_test_n4 order by key limit 20; -explain analyze revoke select on table src_autho_test_n4 from user hive_test_user; +explain profile revoke select on table src_autho_test_n4 from user hive_test_user; -explain analyze grant select(key) on table src_autho_test_n4 to user hive_test_user; +explain profile grant select(key) on table src_autho_test_n4 to user hive_test_user; -explain analyze revoke select(key) on table src_autho_test_n4 from user hive_test_user; +explain profile revoke select(key) on table src_autho_test_n4 from user hive_test_user; -explain analyze +explain profile create role sRc_roLE; create role sRc_roLE; -explain analyze +explain profile grant role sRc_roLE to user hive_test_user; grant role sRc_roLE to user hive_test_user; -explain analyze show role grant user hive_test_user; +explain profile show role grant user hive_test_user; -explain analyze drop role sRc_roLE; +explain profile drop role sRc_roLE; drop role sRc_roLE; set hive.security.authorization.enabled=false; drop table src_autho_test_n4; -explain analyze drop view v_n5; +explain profile drop view v_n5; -explain analyze create view v_n5 as with cte as (select * from src order by key limit 5) +explain profile create view v_n5 as with cte as (select * from src order by key limit 5) select * from cte; -explain analyze with cte as (select * from src order by key limit 5) +explain profile with cte as (select * from src order by key limit 5) select * from cte; create table orc_merge5_n1 (userid bigint, string1 string, subtype double, decimal1 decimal(38,0), ts timestamp) stored as orc; @@ -130,7 +130,7 @@ set hive.merge.tezfiles=true; set hive.merge.mapfiles=true; set hive.merge.mapredfiles=true; -explain analyze insert overwrite table orc_merge5_n1 select userid,string1,subtype,decimal1,ts from orc_merge5_n1 where userid<=13; +explain profile insert overwrite table orc_merge5_n1 select userid,string1,subtype,decimal1,ts from orc_merge5_n1 where userid<=13; drop table orc_merge5_n1; @@ -161,7 +161,7 @@ insert overwrite table tab_n2 partition (ds='2008-04-08') select key,value from srcbucket_mapjoin_n4; set hive.convert.join.bucket.mapjoin.tez = true; -explain analyze +explain profile select a.key, a.value, b.value from tab_n2 a join tab_part_n3 b on a.key = b.key; diff --git a/ql/src/test/queries/clientpositive/explainanalyze_4.q b/ql/src/test/queries/clientpositive/explainprofile_4.q similarity index 96% rename from ql/src/test/queries/clientpositive/explainanalyze_4.q rename to ql/src/test/queries/clientpositive/explainprofile_4.q index 6daba22caa..9ac0b0f13f 100644 --- a/ql/src/test/queries/clientpositive/explainanalyze_4.q +++ b/ql/src/test/queries/clientpositive/explainprofile_4.q @@ -9,7 +9,7 @@ set hive.auto.convert.join=false; set hive.optimize.dynamic.partition.hashjoin=false; -- First try with regular mergejoin -explain analyze +explain profile select * from alltypesorc a join alltypesorc b on a.cint = b.cint @@ -24,7 +24,7 @@ where a.cint between 1000000 and 3000000 and b.cbigint is not null order by a.cint; -explain analyze +explain profile select count(*) from alltypesorc a join alltypesorc b on a.cint = b.cint @@ -37,7 +37,7 @@ from alltypesorc a join alltypesorc b on a.cint = b.cint where a.cint between 1000000 and 3000000 and b.cbigint is not null; -explain analyze +explain profile select a.csmallint, count(*) c1 from alltypesorc a join alltypesorc b on a.cint = b.cint @@ -61,7 +61,7 @@ set hive.stats.fetch.column.stats=false; set hive.exec.reducers.bytes.per.reducer=200000; -- Try with dynamically partitioned hashjoin -explain analyze +explain profile select * from alltypesorc a join alltypesorc b on a.cint = b.cint @@ -76,7 +76,7 @@ where a.cint between 1000000 and 3000000 and b.cbigint is not null order by a.cint; -explain analyze +explain profile select count(*) from alltypesorc a join alltypesorc b on a.cint = b.cint @@ -89,7 +89,7 @@ from alltypesorc a join alltypesorc b on a.cint = b.cint where a.cint between 1000000 and 3000000 and b.cbigint is not null; -explain analyze +explain profile select a.csmallint, count(*) c1 from alltypesorc a join alltypesorc b on a.cint = b.cint diff --git a/ql/src/test/queries/clientpositive/explainanalyze_5.q b/ql/src/test/queries/clientpositive/explainprofile_5.q similarity index 88% rename from ql/src/test/queries/clientpositive/explainanalyze_5.q rename to ql/src/test/queries/clientpositive/explainprofile_5.q index 11296a9029..71c63b0d65 100644 --- a/ql/src/test/queries/clientpositive/explainanalyze_5.q +++ b/ql/src/test/queries/clientpositive/explainprofile_5.q @@ -10,15 +10,15 @@ drop table src_stats_n0; create table src_stats_n0 as select * from src; -explain analyze analyze table src_stats_n0 compute statistics; +explain profile analyze table src_stats_n0 compute statistics; -explain analyze analyze table src_stats_n0 compute statistics for columns; +explain profile analyze table src_stats_n0 compute statistics for columns; drop table src_multi2_n7; create table src_multi2_n7 like src; -explain analyze insert overwrite table src_multi2_n7 select subq.key, src.value from (select * from src union select * from src1)subq join src on subq.key=src.key; +explain profile insert overwrite table src_multi2_n7 select subq.key, src.value from (select * from src union select * from src1)subq join src on subq.key=src.key; select count(*) from (select * from src union select * from src1)subq; @@ -48,7 +48,7 @@ insert into table acid_uami_n2 values select * from acid_uami_n2 order by de; -explain analyze update acid_uami_n2 set de = 3.14 where de = 109.23 or de = 119.23; +explain profile update acid_uami_n2 set de = 3.14 where de = 109.23 or de = 119.23; select * from acid_uami_n2 order by de; @@ -79,7 +79,7 @@ create table acid_dot_n0( select count(*) from acid_dot_n0; -explain analyze delete from acid_dot_n0 where cint < -1070551679; +explain profile delete from acid_dot_n0 where cint < -1070551679; select count(*) from acid_dot_n0; diff --git a/ql/src/test/queries/clientpositive/results_cache_2.q b/ql/src/test/queries/clientpositive/results_cache_2.q index bc8965a57e..42c20ad5c8 100644 --- a/ql/src/test/queries/clientpositive/results_cache_2.q +++ b/ql/src/test/queries/clientpositive/results_cache_2.q @@ -42,10 +42,10 @@ select c1, count(*) from (select current_timestamp c1, value from src where key < 10) q group by c1; --- Test 4: cache disabled for explain analyze -set test.comment=EXPLAIN ANALYZE should not use the cache. This query just previously used the cache in Test 2; +-- Test 4: cache disabled for explain profile +set test.comment=EXPLAIN PROFILE should not use the cache. This query just previously used the cache in Test 2; set test.comment; -explain analyze +explain profile select c1, count(*) from (select sign(value) c1, value from src where key < 10) q group by c1; diff --git a/ql/src/test/queries/clientpositive/retry_failure_stat_changes.q b/ql/src/test/queries/clientpositive/retry_failure_stat_changes.q index 78825385ca..edf1a172e1 100644 --- a/ql/src/test/queries/clientpositive/retry_failure_stat_changes.q +++ b/ql/src/test/queries/clientpositive/retry_failure_stat_changes.q @@ -16,10 +16,10 @@ explain REOPTIMIZATION select sum(u*p) from tx_n2 join px on (u=p) where u<10 and p>2; set hive.auto.convert.join=false; -explain analyze +explain profile select sum(u*p) from tx_n2 join px on (u=p) where u<10 and p>2; set hive.auto.convert.join=true; -explain analyze +explain profile select sum(u*p) from tx_n2 join px on (u=p) where u<10 and p>2; set zzz=1; diff --git a/ql/src/test/queries/clientpositive/stat_estimate_drill.q b/ql/src/test/queries/clientpositive/stat_estimate_drill.q index 7ba5fe9fdf..2c3412ad0c 100644 --- a/ql/src/test/queries/clientpositive/stat_estimate_drill.q +++ b/ql/src/test/queries/clientpositive/stat_estimate_drill.q @@ -20,16 +20,16 @@ insert into t3 analyze table t3 compute statistics for columns; -explain analyze select sum(a) from t3 where b in (2,3) group by b; +explain profile select sum(a) from t3 where b in (2,3) group by b; -explain analyze select sum(a) from t3 where a=1 or a=2 group by b; -explain analyze select sum(a) from t3 where a=1 or (a=2 and b=3) group by b; -explain analyze select sum(a) from t3 where a=1 group by b; -explain analyze select sum(a) from t3 where a=1 and b=2 group by b; -explain analyze select sum(a) from t3 where a=1 and b=2 and c=3 group by b; +explain profile select sum(a) from t3 where a=1 or a=2 group by b; +explain profile select sum(a) from t3 where a=1 or (a=2 and b=3) group by b; +explain profile select sum(a) from t3 where a=1 group by b; +explain profile select sum(a) from t3 where a=1 and b=2 group by b; +explain profile select sum(a) from t3 where a=1 and b=2 and c=3 group by b; -- FIXME: for the below case; we right now get an IN which is estimated as 1/3 - might worth consider improving set hive.semantic.analyzer.hook=; -explain analyze select sum(a) from t3 where (a=1 and b=2) or (a=2 and b=3) or (a=3 and b=4) group by b; +explain profile select sum(a) from t3 where (a=1 and b=2) or (a=2 and b=3) or (a=3 and b=4) group by b; diff --git a/ql/src/test/queries/clientpositive/stat_estimate_related_col.q b/ql/src/test/queries/clientpositive/stat_estimate_related_col.q index 5aa380ff1f..ceb868e6e1 100644 --- a/ql/src/test/queries/clientpositive/stat_estimate_related_col.q +++ b/ql/src/test/queries/clientpositive/stat_estimate_related_col.q @@ -24,27 +24,27 @@ select * from t1 union all select * from t1 union all select * from t1 union all analyze table t1 compute statistics for columns; analyze table t8 compute statistics for columns; -explain analyze select sum(a) from t8 where b in (2,3) group by b; -explain analyze select sum(a) from t8 where b=2 group by b; +explain profile select sum(a) from t8 where b in (2,3) group by b; +explain profile select sum(a) from t8 where b=2 group by b; -explain analyze select sum(a) from t1 where 2=b and b=2 group by b; +explain profile select sum(a) from t1 where 2=b and b=2 group by b; -explain analyze select sum(a) from t1 where b in (2,3) and b=2 group by b; -explain analyze select sum(a) from t8 where b in (2,3) and b=2 group by b; +explain profile select sum(a) from t1 where b in (2,3) and b=2 group by b; +explain profile select sum(a) from t8 where b in (2,3) and b=2 group by b; -explain analyze select count(*) from t8 ta, t8 tb where ta.a = tb.b and ta.a=3; +explain profile select count(*) from t8 ta, t8 tb where ta.a = tb.b and ta.a=3; -explain analyze select sum(a) from t8 where b in (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50) and b=2 and b=2 and 2=b group by b; +explain profile select sum(a) from t8 where b in (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50) and b=2 and b=2 and 2=b group by b; -explain analyze select sum(a) from t8 where b=2 and (b = 1 or b=2) group by b; +explain profile select sum(a) from t8 where b=2 and (b = 1 or b=2) group by b; set accurate.estimate.checker.absolute.error=8; -explain analyze select sum(a) from t8 where b=2 and (b = 1 or b=2) and (b=1 or b=3) group by b; +explain profile select sum(a) from t8 where b=2 and (b = 1 or b=2) and (b=1 or b=3) group by b; -explain analyze select sum(a) from t8 where +explain profile select sum(a) from t8 where b=2 and (b = 1 or b=2) and a=3 and (a = 3 or a=4) diff --git a/ql/src/test/results/clientpositive/estimate_pkfk_push.q.out b/ql/src/test/results/clientpositive/estimate_pkfk_push.q.out index 07c62f2d87..c2e2cb769d 100644 --- a/ql/src/test/results/clientpositive/estimate_pkfk_push.q.out +++ b/ql/src/test/results/clientpositive/estimate_pkfk_push.q.out @@ -141,7 +141,7 @@ POSTHOOK: Input: default@ship_types POSTHOOK: Input: default@ships POSTHOOK: Input: default@torpedos #### A masked pattern was here #### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select s.id from @@ -157,7 +157,7 @@ PREHOOK: Input: default@ship_types PREHOOK: Input: default@ships PREHOOK: Input: default@torpedos #### A masked pattern was here #### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select s.id from diff --git a/ql/src/test/results/clientpositive/llap/estimate_pkfk_filtered_fk.q.out b/ql/src/test/results/clientpositive/llap/estimate_pkfk_filtered_fk.q.out index a9facbfac1..f74b2b3f0c 100644 --- a/ql/src/test/results/clientpositive/llap/estimate_pkfk_filtered_fk.q.out +++ b/ql/src/test/results/clientpositive/llap/estimate_pkfk_filtered_fk.q.out @@ -143,7 +143,7 @@ POSTHOOK: Input: default@ship_types POSTHOOK: Input: default@ships POSTHOOK: Input: default@torpedos #### A masked pattern was here #### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select s.id from @@ -160,7 +160,7 @@ PREHOOK: Input: default@ship_types PREHOOK: Input: default@ships PREHOOK: Input: default@torpedos #### A masked pattern was here #### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select s.id from @@ -250,7 +250,7 @@ POSTHOOK: type: QUERY POSTHOOK: Input: default@ship_types POSTHOOK: Input: default@ships #### A masked pattern was here #### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select s.id from @@ -264,7 +264,7 @@ PREHOOK: type: QUERY PREHOOK: Input: default@ship_types PREHOOK: Input: default@ships #### A masked pattern was here #### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select s.id from diff --git a/ql/src/test/results/clientpositive/llap/estimate_pkfk_fknulls.q.out b/ql/src/test/results/clientpositive/llap/estimate_pkfk_fknulls.q.out index 8aef47bef5..86adc2dc98 100644 --- a/ql/src/test/results/clientpositive/llap/estimate_pkfk_fknulls.q.out +++ b/ql/src/test/results/clientpositive/llap/estimate_pkfk_fknulls.q.out @@ -144,7 +144,7 @@ POSTHOOK: type: QUERY POSTHOOK: Input: default@rx0 POSTHOOK: Input: default@sr0 #### A masked pattern was here #### -PREHOOK: query: explain analyze select 1 +PREHOOK: query: explain profile select 1 from default.sr0 store_returns , default.rx0 reason where sr_reason_sk = r_reason_sk and r_reason_id = 'AAAAAAAAAAAAAAAA' @@ -152,7 +152,7 @@ PREHOOK: type: QUERY PREHOOK: Input: default@rx0 PREHOOK: Input: default@sr0 #### A masked pattern was here #### -POSTHOOK: query: explain analyze select 1 +POSTHOOK: query: explain profile select 1 from default.sr0 store_returns , default.rx0 reason where sr_reason_sk = r_reason_sk and r_reason_id = 'AAAAAAAAAAAAAAAA' diff --git a/ql/src/test/results/clientpositive/llap/estimate_pkfk_push.q.out b/ql/src/test/results/clientpositive/llap/estimate_pkfk_push.q.out index 2ba22d68bc..12fd8c3dfb 100644 --- a/ql/src/test/results/clientpositive/llap/estimate_pkfk_push.q.out +++ b/ql/src/test/results/clientpositive/llap/estimate_pkfk_push.q.out @@ -141,7 +141,7 @@ POSTHOOK: Input: default@ship_types POSTHOOK: Input: default@ships POSTHOOK: Input: default@torpedos #### A masked pattern was here #### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select s.id from @@ -157,7 +157,7 @@ PREHOOK: Input: default@ship_types PREHOOK: Input: default@ships PREHOOK: Input: default@torpedos #### A masked pattern was here #### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select s.id from diff --git a/ql/src/test/results/clientpositive/llap/explainanalyze_2.q.out b/ql/src/test/results/clientpositive/llap/explainprofile_2.q.out similarity index 99% rename from ql/src/test/results/clientpositive/llap/explainanalyze_2.q.out rename to ql/src/test/results/clientpositive/llap/explainprofile_2.q.out index 36bd120028..8b22820a42 100644 --- a/ql/src/test/results/clientpositive/llap/explainanalyze_2.q.out +++ b/ql/src/test/results/clientpositive/llap/explainprofile_2.q.out @@ -20,7 +20,7 @@ POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Input: default@src1 #### A masked pattern was here #### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile SELECT x.key, z.value, y.value FROM src1 x JOIN src y ON (x.key = y.key) JOIN (select * from src1 union select * from src)z ON (x.value = z.value) @@ -32,7 +32,7 @@ PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Input: default@src1 #### A masked pattern was here #### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile SELECT x.key, z.value, y.value FROM src1 x JOIN src y ON (x.key = y.key) JOIN (select * from src1 union select * from src)z ON (x.value = z.value) @@ -201,7 +201,7 @@ POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Input: default@src1 #### A masked pattern was here #### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile SELECT x.key, y.value FROM src1 x JOIN src y ON (x.key = y.key) JOIN (select * from src1 union select * from src)z ON (x.value = z.value) @@ -217,7 +217,7 @@ PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Input: default@src1 #### A masked pattern was here #### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile SELECT x.key, y.value FROM src1 x JOIN src y ON (x.key = y.key) JOIN (select * from src1 union select * from src)z ON (x.value = z.value) @@ -607,13 +607,13 @@ POSTHOOK: type: QUERY POSTHOOK: Input: default@tab_n6 POSTHOOK: Input: default@tab_n6@ds=2008-04-08 #### A masked pattern was here #### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select s1.key as key, s1.value as value from tab_n6 s1 join tab_n6 s3 on s1.key=s3.key PREHOOK: type: QUERY PREHOOK: Input: default@tab_n6 PREHOOK: Input: default@tab_n6@ds=2008-04-08 #### A masked pattern was here #### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select s1.key as key, s1.value as value from tab_n6 s1 join tab_n6 s3 on s1.key=s3.key POSTHOOK: type: QUERY POSTHOOK: Input: default@tab_n6 @@ -652,13 +652,13 @@ POSTHOOK: type: QUERY POSTHOOK: Input: default@tab_n6 POSTHOOK: Input: default@tab_n6@ds=2008-04-08 #### A masked pattern was here #### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select s1.key as key, s1.value as value from tab_n6 s1 join tab_n6 s3 on s1.key=s3.key join tab_n6 s2 on s1.value=s2.value PREHOOK: type: QUERY PREHOOK: Input: default@tab_n6 PREHOOK: Input: default@tab_n6@ds=2008-04-08 #### A masked pattern was here #### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select s1.key as key, s1.value as value from tab_n6 s1 join tab_n6 s3 on s1.key=s3.key join tab_n6 s2 on s1.value=s2.value POSTHOOK: type: QUERY POSTHOOK: Input: default@tab_n6 @@ -725,7 +725,7 @@ POSTHOOK: Input: default@tab2_n3@ds=2008-04-08 POSTHOOK: Input: default@tab_n6 POSTHOOK: Input: default@tab_n6@ds=2008-04-08 #### A masked pattern was here #### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select s1.key as key, s1.value as value from tab_n6 s1 join tab2_n3 s3 on s1.key=s3.key PREHOOK: type: QUERY PREHOOK: Input: default@tab2_n3 @@ -733,7 +733,7 @@ PREHOOK: Input: default@tab2_n3@ds=2008-04-08 PREHOOK: Input: default@tab_n6 PREHOOK: Input: default@tab_n6@ds=2008-04-08 #### A masked pattern was here #### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select s1.key as key, s1.value as value from tab_n6 s1 join tab2_n3 s3 on s1.key=s3.key POSTHOOK: type: QUERY POSTHOOK: Input: default@tab2_n3 @@ -778,7 +778,7 @@ POSTHOOK: Input: default@tab2_n3@ds=2008-04-08 POSTHOOK: Input: default@tab_n6 POSTHOOK: Input: default@tab_n6@ds=2008-04-08 #### A masked pattern was here #### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select s1.key as key, s1.value as value from tab_n6 s1 join tab2_n3 s3 on s1.key=s3.key join tab2_n3 s2 on s1.value=s2.value PREHOOK: type: QUERY PREHOOK: Input: default@tab2_n3 @@ -786,7 +786,7 @@ PREHOOK: Input: default@tab2_n3@ds=2008-04-08 PREHOOK: Input: default@tab_n6 PREHOOK: Input: default@tab_n6@ds=2008-04-08 #### A masked pattern was here #### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select s1.key as key, s1.value as value from tab_n6 s1 join tab2_n3 s3 on s1.key=s3.key join tab2_n3 s2 on s1.value=s2.value POSTHOOK: type: QUERY POSTHOOK: Input: default@tab2_n3 @@ -861,7 +861,7 @@ POSTHOOK: Input: default@tab_n6@ds=2008-04-08 POSTHOOK: Input: default@tab_part_n7 POSTHOOK: Input: default@tab_part_n7@ds=2008-04-08 #### A masked pattern was here #### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select count(*) from (select s1.key as key, s1.value as value from tab_n6 s1 join tab_n6 s3 on s1.key=s3.key UNION ALL select s2.key as key, s2.value as value from tab_n6 s2 @@ -872,7 +872,7 @@ PREHOOK: Input: default@tab_n6@ds=2008-04-08 PREHOOK: Input: default@tab_part_n7 PREHOOK: Input: default@tab_part_n7@ds=2008-04-08 #### A masked pattern was here #### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select count(*) from (select s1.key as key, s1.value as value from tab_n6 s1 join tab_n6 s3 on s1.key=s3.key UNION ALL select s2.key as key, s2.value as value from tab_n6 s2 @@ -960,7 +960,7 @@ POSTHOOK: Input: default@tab_n6@ds=2008-04-08 POSTHOOK: Input: default@tab_part_n7 POSTHOOK: Input: default@tab_part_n7@ds=2008-04-08 #### A masked pattern was here #### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select count(*) from (select s1.key as key, s1.value as value from tab_n6 s1 join tab_n6 s3 on s1.key=s3.key join tab_n6 s2 on s1.value=s2.value UNION ALL select s2.key as key, s2.value as value from tab_n6 s2 @@ -971,7 +971,7 @@ PREHOOK: Input: default@tab_n6@ds=2008-04-08 PREHOOK: Input: default@tab_part_n7 PREHOOK: Input: default@tab_part_n7@ds=2008-04-08 #### A masked pattern was here #### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select count(*) from (select s1.key as key, s1.value as value from tab_n6 s1 join tab_n6 s3 on s1.key=s3.key join tab_n6 s2 on s1.value=s2.value UNION ALL select s2.key as key, s2.value as value from tab_n6 s2 @@ -1130,7 +1130,7 @@ POSTHOOK: Input: default@src1 POSTHOOK: Output: default@a_n14 POSTHOOK: Output: default@b_n10 POSTHOOK: Output: default@c_n3 -PREHOOK: query: explain analyze +PREHOOK: query: explain profile from ( SELECT x.key, y.value @@ -1154,7 +1154,7 @@ PREHOOK: Input: default@src1 PREHOOK: Output: default@a_n14 PREHOOK: Output: default@b_n10 PREHOOK: Output: default@c_n3 -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile from ( SELECT x.key, y.value @@ -1498,7 +1498,7 @@ POSTHOOK: Input: default@src1 POSTHOOK: Output: default@a_n14 POSTHOOK: Output: default@b_n10 POSTHOOK: Output: default@c_n3 -PREHOOK: query: explain analyze +PREHOOK: query: explain profile FROM ( SELECT x.key as key, y.value as value from src1 x JOIN src y ON (x.key = y.key) @@ -1519,7 +1519,7 @@ PREHOOK: Input: default@src1 PREHOOK: Output: default@a_n14 PREHOOK: Output: default@b_n10 PREHOOK: Output: default@c_n3 -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile FROM ( SELECT x.key as key, y.value as value from src1 x JOIN src y ON (x.key = y.key) @@ -1873,7 +1873,7 @@ POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: default@dest1_n105 POSTHOOK: Output: default@dest2_n29 -PREHOOK: query: explain analyze +PREHOOK: query: explain profile FROM (select 'tst1' as key, cast(count(1) as string) as value from src s1 UNION DISTINCT select s2.key as key, s2.value as value from src s2) unionsrc_n3 @@ -1883,7 +1883,7 @@ PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Output: default@dest1_n105 PREHOOK: Output: default@dest2_n29 -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile FROM (select 'tst1' as key, cast(count(1) as string) as value from src s1 UNION DISTINCT select s2.key as key, s2.value as value from src s2) unionsrc_n3 @@ -1991,7 +1991,7 @@ POSTHOOK: Input: default@srcpart@ds=2008-04-08/hr=12 POSTHOOK: Input: default@srcpart@ds=2008-04-09/hr=11 POSTHOOK: Input: default@srcpart@ds=2008-04-09/hr=12 #### A masked pattern was here #### -PREHOOK: query: explain analyze FROM UNIQUEJOIN PRESERVE src a_n14 (a_n14.key), PRESERVE src1 b_n10 (b_n10.key), PRESERVE srcpart c_n3 (c_n3.key) SELECT a_n14.key, b_n10.key, c_n3.key +PREHOOK: query: explain profile FROM UNIQUEJOIN PRESERVE src a_n14 (a_n14.key), PRESERVE src1 b_n10 (b_n10.key), PRESERVE srcpart c_n3 (c_n3.key) SELECT a_n14.key, b_n10.key, c_n3.key PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Input: default@src1 @@ -2001,7 +2001,7 @@ PREHOOK: Input: default@srcpart@ds=2008-04-08/hr=12 PREHOOK: Input: default@srcpart@ds=2008-04-09/hr=11 PREHOOK: Input: default@srcpart@ds=2008-04-09/hr=12 #### A masked pattern was here #### -POSTHOOK: query: explain analyze FROM UNIQUEJOIN PRESERVE src a_n14 (a_n14.key), PRESERVE src1 b_n10 (b_n10.key), PRESERVE srcpart c_n3 (c_n3.key) SELECT a_n14.key, b_n10.key, c_n3.key +POSTHOOK: query: explain profile FROM UNIQUEJOIN PRESERVE src a_n14 (a_n14.key), PRESERVE src1 b_n10 (b_n10.key), PRESERVE srcpart c_n3 (c_n3.key) SELECT a_n14.key, b_n10.key, c_n3.key POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Input: default@src1 @@ -2072,7 +2072,7 @@ POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: default@dest1_n105 POSTHOOK: Output: default@dest2_n29 -PREHOOK: query: explain analyze +PREHOOK: query: explain profile FROM ( select key, value from ( select 'tst1' as key, cast(count(1) as string) as value, 'tst1' as value2 from src s1 @@ -2088,7 +2088,7 @@ PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Output: default@dest1_n105 PREHOOK: Output: default@dest2_n29 -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile FROM ( select key, value from ( select 'tst1' as key, cast(count(1) as string) as value, 'tst1' as value2 from src s1 @@ -2221,7 +2221,7 @@ POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: default@dest1_n105 POSTHOOK: Output: default@dest2_n29 -PREHOOK: query: explain analyze +PREHOOK: query: explain profile FROM ( select 'tst1' as key, cast(count(1) as string) as value, 'tst1' as value2 from src s1 UNION all @@ -2234,7 +2234,7 @@ PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Output: default@dest1_n105 PREHOOK: Output: default@dest2_n29 -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile FROM ( select 'tst1' as key, cast(count(1) as string) as value, 'tst1' as value2 from src s1 UNION all diff --git a/ql/src/test/results/clientpositive/llap/results_cache_2.q.out b/ql/src/test/results/clientpositive/llap/results_cache_2.q.out index d4104aee9e..1f38014e42 100644 --- a/ql/src/test/results/clientpositive/llap/results_cache_2.q.out +++ b/ql/src/test/results/clientpositive/llap/results_cache_2.q.out @@ -197,7 +197,7 @@ STAGE PLANS: Processor Tree: ListSink -test.comment=EXPLAIN ANALYZE should not use the cache. This query just previously used the cache in Test 2 +test.comment=EXPLAIN PROFILE should not use the cache. This query just previously used the cache in Test 2 PREHOOK: query: select c1, count(*) from (select sign(value) c1, value from src where key < 10) q group by c1 @@ -210,14 +210,14 @@ group by c1 POSTHOOK: type: QUERY POSTHOOK: Input: default@src #### A masked pattern was here #### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select c1, count(*) from (select sign(value) c1, value from src where key < 10) q group by c1 PREHOOK: type: QUERY PREHOOK: Input: default@src #### A masked pattern was here #### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select c1, count(*) from (select sign(value) c1, value from src where key < 10) q group by c1 diff --git a/ql/src/test/results/clientpositive/llap/retry_failure_stat_changes.q.out b/ql/src/test/results/clientpositive/llap/retry_failure_stat_changes.q.out index 8ec6624ae3..a7f70a1d56 100644 --- a/ql/src/test/results/clientpositive/llap/retry_failure_stat_changes.q.out +++ b/ql/src/test/results/clientpositive/llap/retry_failure_stat_changes.q.out @@ -109,13 +109,13 @@ POSTHOOK: type: QUERY POSTHOOK: Input: default@px POSTHOOK: Input: default@tx_n2 #### A masked pattern was here #### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select sum(u*p) from tx_n2 join px on (u=p) where u<10 and p>2 PREHOOK: type: QUERY PREHOOK: Input: default@px PREHOOK: Input: default@tx_n2 #### A masked pattern was here #### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select sum(u*p) from tx_n2 join px on (u=p) where u<10 and p>2 POSTHOOK: type: QUERY POSTHOOK: Input: default@px @@ -172,13 +172,13 @@ POSTHOOK: type: QUERY POSTHOOK: Input: default@px POSTHOOK: Input: default@tx_n2 #### A masked pattern was here #### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select sum(u*p) from tx_n2 join px on (u=p) where u<10 and p>2 PREHOOK: type: QUERY PREHOOK: Input: default@px PREHOOK: Input: default@tx_n2 #### A masked pattern was here #### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select sum(u*p) from tx_n2 join px on (u=p) where u<10 and p>2 POSTHOOK: type: QUERY POSTHOOK: Input: default@px diff --git a/ql/src/test/results/clientpositive/stat_estimate_drill.q.out b/ql/src/test/results/clientpositive/stat_estimate_drill.q.out index e95ae413d0..bd461443c0 100644 --- a/ql/src/test/results/clientpositive/stat_estimate_drill.q.out +++ b/ql/src/test/results/clientpositive/stat_estimate_drill.q.out @@ -70,11 +70,11 @@ POSTHOOK: query: select sum(a) from t3 where b in (2,3) group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t3 #### A masked pattern was here #### -PREHOOK: query: explain analyze select sum(a) from t3 where b in (2,3) group by b +PREHOOK: query: explain profile select sum(a) from t3 where b in (2,3) group by b PREHOOK: type: QUERY PREHOOK: Input: default@t3 #### A masked pattern was here #### -POSTHOOK: query: explain analyze select sum(a) from t3 where b in (2,3) group by b +POSTHOOK: query: explain profile select sum(a) from t3 where b in (2,3) group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t3 #### A masked pattern was here #### @@ -141,11 +141,11 @@ POSTHOOK: query: select sum(a) from t3 where a=1 or a=2 group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t3 #### A masked pattern was here #### -PREHOOK: query: explain analyze select sum(a) from t3 where a=1 or a=2 group by b +PREHOOK: query: explain profile select sum(a) from t3 where a=1 or a=2 group by b PREHOOK: type: QUERY PREHOOK: Input: default@t3 #### A masked pattern was here #### -POSTHOOK: query: explain analyze select sum(a) from t3 where a=1 or a=2 group by b +POSTHOOK: query: explain profile select sum(a) from t3 where a=1 or a=2 group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t3 #### A masked pattern was here #### @@ -212,11 +212,11 @@ POSTHOOK: query: select sum(a) from t3 where a=1 or (a=2 and b=3) group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t3 #### A masked pattern was here #### -PREHOOK: query: explain analyze select sum(a) from t3 where a=1 or (a=2 and b=3) group by b +PREHOOK: query: explain profile select sum(a) from t3 where a=1 or (a=2 and b=3) group by b PREHOOK: type: QUERY PREHOOK: Input: default@t3 #### A masked pattern was here #### -POSTHOOK: query: explain analyze select sum(a) from t3 where a=1 or (a=2 and b=3) group by b +POSTHOOK: query: explain profile select sum(a) from t3 where a=1 or (a=2 and b=3) group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t3 #### A masked pattern was here #### diff --git a/ql/src/test/results/clientpositive/stat_estimate_related_col.q.out b/ql/src/test/results/clientpositive/stat_estimate_related_col.q.out index 8546612583..f78fc7c17a 100644 --- a/ql/src/test/results/clientpositive/stat_estimate_related_col.q.out +++ b/ql/src/test/results/clientpositive/stat_estimate_related_col.q.out @@ -74,11 +74,11 @@ POSTHOOK: query: select sum(a) from t8 where b in (2,3) group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t8 #### A masked pattern was here #### -PREHOOK: query: explain analyze select sum(a) from t8 where b in (2,3) group by b +PREHOOK: query: explain profile select sum(a) from t8 where b in (2,3) group by b PREHOOK: type: QUERY PREHOOK: Input: default@t8 #### A masked pattern was here #### -POSTHOOK: query: explain analyze select sum(a) from t8 where b in (2,3) group by b +POSTHOOK: query: explain profile select sum(a) from t8 where b in (2,3) group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t8 #### A masked pattern was here #### @@ -145,11 +145,11 @@ POSTHOOK: query: select sum(a) from t8 where b=2 group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t8 #### A masked pattern was here #### -PREHOOK: query: explain analyze select sum(a) from t8 where b=2 group by b +PREHOOK: query: explain profile select sum(a) from t8 where b=2 group by b PREHOOK: type: QUERY PREHOOK: Input: default@t8 #### A masked pattern was here #### -POSTHOOK: query: explain analyze select sum(a) from t8 where b=2 group by b +POSTHOOK: query: explain profile select sum(a) from t8 where b=2 group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t8 #### A masked pattern was here #### @@ -220,11 +220,11 @@ POSTHOOK: query: select sum(a) from t1 where 2=b and b=2 group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t1 #### A masked pattern was here #### -PREHOOK: query: explain analyze select sum(a) from t1 where 2=b and b=2 group by b +PREHOOK: query: explain profile select sum(a) from t1 where 2=b and b=2 group by b PREHOOK: type: QUERY PREHOOK: Input: default@t1 #### A masked pattern was here #### -POSTHOOK: query: explain analyze select sum(a) from t1 where 2=b and b=2 group by b +POSTHOOK: query: explain profile select sum(a) from t1 where 2=b and b=2 group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t1 #### A masked pattern was here #### @@ -295,11 +295,11 @@ POSTHOOK: query: select sum(a) from t1 where b in (2,3) and b=2 group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t1 #### A masked pattern was here #### -PREHOOK: query: explain analyze select sum(a) from t1 where b in (2,3) and b=2 group by b +PREHOOK: query: explain profile select sum(a) from t1 where b in (2,3) and b=2 group by b PREHOOK: type: QUERY PREHOOK: Input: default@t1 #### A masked pattern was here #### -POSTHOOK: query: explain analyze select sum(a) from t1 where b in (2,3) and b=2 group by b +POSTHOOK: query: explain profile select sum(a) from t1 where b in (2,3) and b=2 group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t1 #### A masked pattern was here #### @@ -370,11 +370,11 @@ POSTHOOK: query: select sum(a) from t8 where b in (2,3) and b=2 group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t8 #### A masked pattern was here #### -PREHOOK: query: explain analyze select sum(a) from t8 where b in (2,3) and b=2 group by b +PREHOOK: query: explain profile select sum(a) from t8 where b in (2,3) and b=2 group by b PREHOOK: type: QUERY PREHOOK: Input: default@t8 #### A masked pattern was here #### -POSTHOOK: query: explain analyze select sum(a) from t8 where b in (2,3) and b=2 group by b +POSTHOOK: query: explain profile select sum(a) from t8 where b in (2,3) and b=2 group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t8 #### A masked pattern was here #### @@ -445,11 +445,11 @@ POSTHOOK: query: select count(*) from t8 ta, t8 tb where ta.a = tb.b and ta.a=3 POSTHOOK: type: QUERY POSTHOOK: Input: default@t8 #### A masked pattern was here #### -PREHOOK: query: explain analyze select count(*) from t8 ta, t8 tb where ta.a = tb.b and ta.a=3 +PREHOOK: query: explain profile select count(*) from t8 ta, t8 tb where ta.a = tb.b and ta.a=3 PREHOOK: type: QUERY PREHOOK: Input: default@t8 #### A masked pattern was here #### -POSTHOOK: query: explain analyze select count(*) from t8 ta, t8 tb where ta.a = tb.b and ta.a=3 +POSTHOOK: query: explain profile select count(*) from t8 ta, t8 tb where ta.a = tb.b and ta.a=3 POSTHOOK: type: QUERY POSTHOOK: Input: default@t8 #### A masked pattern was here #### @@ -547,11 +547,11 @@ POSTHOOK: query: select sum(a) from t8 where b in (1,2,3,4,5,6,7,8,9,10,11,12,13 POSTHOOK: type: QUERY POSTHOOK: Input: default@t8 #### A masked pattern was here #### -PREHOOK: query: explain analyze select sum(a) from t8 where b in (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50) and b=2 and b=2 and 2=b group by b +PREHOOK: query: explain profile select sum(a) from t8 where b in (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50) and b=2 and b=2 and 2=b group by b PREHOOK: type: QUERY PREHOOK: Input: default@t8 #### A masked pattern was here #### -POSTHOOK: query: explain analyze select sum(a) from t8 where b in (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50) and b=2 and b=2 and 2=b group by b +POSTHOOK: query: explain profile select sum(a) from t8 where b in (1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50) and b=2 and b=2 and 2=b group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t8 #### A masked pattern was here #### @@ -622,11 +622,11 @@ POSTHOOK: query: select sum(a) from t8 where b=2 and (b = 1 or b=2) group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t8 #### A masked pattern was here #### -PREHOOK: query: explain analyze select sum(a) from t8 where b=2 and (b = 1 or b=2) group by b +PREHOOK: query: explain profile select sum(a) from t8 where b=2 and (b = 1 or b=2) group by b PREHOOK: type: QUERY PREHOOK: Input: default@t8 #### A masked pattern was here #### -POSTHOOK: query: explain analyze select sum(a) from t8 where b=2 and (b = 1 or b=2) group by b +POSTHOOK: query: explain profile select sum(a) from t8 where b=2 and (b = 1 or b=2) group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t8 #### A masked pattern was here #### @@ -697,11 +697,11 @@ POSTHOOK: query: select sum(a) from t8 where b=2 and (b = 1 or b=2) and (b=1 or POSTHOOK: type: QUERY POSTHOOK: Input: default@t8 #### A masked pattern was here #### -PREHOOK: query: explain analyze select sum(a) from t8 where b=2 and (b = 1 or b=2) and (b=1 or b=3) group by b +PREHOOK: query: explain profile select sum(a) from t8 where b=2 and (b = 1 or b=2) and (b=1 or b=3) group by b PREHOOK: type: QUERY PREHOOK: Input: default@t8 #### A masked pattern was here #### -POSTHOOK: query: explain analyze select sum(a) from t8 where b=2 and (b = 1 or b=2) and (b=1 or b=3) group by b +POSTHOOK: query: explain profile select sum(a) from t8 where b=2 and (b = 1 or b=2) and (b=1 or b=3) group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t8 #### A masked pattern was here #### @@ -780,7 +780,7 @@ group by b POSTHOOK: type: QUERY POSTHOOK: Input: default@t8 #### A masked pattern was here #### -PREHOOK: query: explain analyze select sum(a) from t8 where +PREHOOK: query: explain profile select sum(a) from t8 where b=2 and (b = 1 or b=2) and a=3 and (a = 3 or a=4) @@ -788,7 +788,7 @@ group by b PREHOOK: type: QUERY PREHOOK: Input: default@t8 #### A masked pattern was here #### -POSTHOOK: query: explain analyze select sum(a) from t8 where +POSTHOOK: query: explain profile select sum(a) from t8 where b=2 and (b = 1 or b=2) and a=3 and (a = 3 or a=4) diff --git a/ql/src/test/results/clientpositive/tez/explainanalyze_1.q.out b/ql/src/test/results/clientpositive/tez/explainprofile_1.q.out similarity index 93% rename from ql/src/test/results/clientpositive/tez/explainanalyze_1.q.out rename to ql/src/test/results/clientpositive/tez/explainprofile_1.q.out index 38da086cac..770c38f283 100644 --- a/ql/src/test/results/clientpositive/tez/explainanalyze_1.q.out +++ b/ql/src/test/results/clientpositive/tez/explainprofile_1.q.out @@ -6,11 +6,11 @@ POSTHOOK: query: select * from src a union all select * from src b limit 10 POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze select * from src a union all select * from src b limit 10 +PREHOOK: query: explain profile select * from src a union all select * from src b limit 10 PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze select * from src a union all select * from src b limit 10 +POSTHOOK: query: explain profile select * from src a union all select * from src b limit 10 POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### @@ -50,11 +50,11 @@ POSTHOOK: query: select key from src POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze select key from src +PREHOOK: query: explain profile select key from src PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze select key from src +POSTHOOK: query: explain profile select key from src POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### @@ -78,12 +78,12 @@ POSTHOOK: type: CREATETABLE_AS_SELECT POSTHOOK: Input: default@src POSTHOOK: Output: database:default POSTHOOK: Output: default@t_n28 -PREHOOK: query: explain analyze create table t_n28 as select key from src +PREHOOK: query: explain profile create table t_n28 as select key from src PREHOOK: type: CREATETABLE_AS_SELECT PREHOOK: Input: default@src PREHOOK: Output: database:default PREHOOK: Output: default@t_n28 -POSTHOOK: query: explain analyze create table t_n28 as select key from src +POSTHOOK: query: explain profile create table t_n28 as select key from src POSTHOOK: type: CREATETABLE_AS_SELECT POSTHOOK: Input: default@src POSTHOOK: Output: database:default @@ -138,11 +138,11 @@ POSTHOOK: query: insert overwrite table t_n28 select key from src POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: default@t_n28 -PREHOOK: query: explain analyze insert overwrite table t_n28 select key from src +PREHOOK: query: explain profile insert overwrite table t_n28 select key from src PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Output: default@t_n28 -POSTHOOK: query: explain analyze insert overwrite table t_n28 select key from src +POSTHOOK: query: explain profile insert overwrite table t_n28 select key from src POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: default@t_n28 @@ -183,11 +183,11 @@ POSTHOOK: query: select key from src limit 10 POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze select key from src limit 10 +PREHOOK: query: explain profile select key from src limit 10 PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze select key from src limit 10 +POSTHOOK: query: explain profile select key from src limit 10 POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### @@ -211,11 +211,11 @@ POSTHOOK: query: select key from src where value < 10 POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze select key from src where value < 10 +PREHOOK: query: explain profile select key from src where value < 10 PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze select key from src where value < 10 +POSTHOOK: query: explain profile select key from src where value < 10 POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### @@ -239,11 +239,11 @@ POSTHOOK: query: select key from src where key < 10 POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze select key from src where key < 10 +PREHOOK: query: explain profile select key from src where key < 10 PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze select key from src where key < 10 +POSTHOOK: query: explain profile select key from src where key < 10 POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### @@ -276,11 +276,11 @@ POSTHOOK: query: select key, count(key) from src group by key POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze select key, count(key) from src group by key +PREHOOK: query: explain profile select key, count(key) from src group by key PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze select key, count(key) from src group by key +POSTHOOK: query: explain profile select key, count(key) from src group by key POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### @@ -322,11 +322,11 @@ POSTHOOK: query: select count(*) from src a join src b on a.key = b.value where POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze select count(*) from src a join src b on a.key = b.value where a.key > 0 +PREHOOK: query: explain profile select count(*) from src a join src b on a.key = b.value where a.key > 0 PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze select count(*) from src a join src b on a.key = b.value where a.key > 0 +POSTHOOK: query: explain profile select count(*) from src a join src b on a.key = b.value where a.key > 0 POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### @@ -375,11 +375,11 @@ POSTHOOK: query: select count(*) from src a join src b on a.key = b.key where a. POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze select count(*) from src a join src b on a.key = b.key where a.key > 0 +PREHOOK: query: explain profile select count(*) from src a join src b on a.key = b.key where a.key > 0 PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze select count(*) from src a join src b on a.key = b.key where a.key > 0 +POSTHOOK: query: explain profile select count(*) from src a join src b on a.key = b.key where a.key > 0 POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### @@ -437,11 +437,11 @@ POSTHOOK: query: select * from src a union all select * from src b POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze select * from src a union all select * from src b +PREHOOK: query: explain profile select * from src a union all select * from src b PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze select * from src a union all select * from src b +POSTHOOK: query: explain profile select * from src a union all select * from src b POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### @@ -488,13 +488,13 @@ FROM src x JOIN src y ON (x.key = y.key) POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: EXPLAIN analyze +PREHOOK: query: explain profile SELECT x.key, y.value FROM src x JOIN src y ON (x.key = y.key) PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: EXPLAIN analyze +POSTHOOK: query: explain profile SELECT x.key, y.value FROM src x JOIN src y ON (x.key = y.key) POSTHOOK: type: QUERY @@ -550,7 +550,7 @@ POSTHOOK: type: QUERY POSTHOOK: Input: cat POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile SELECT TRANSFORM(a.key, a.value) USING 'cat' AS (tkey, tvalue) FROM src a join src b @@ -559,7 +559,7 @@ PREHOOK: type: QUERY PREHOOK: Input: cat PREHOOK: Input: default@src PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile SELECT TRANSFORM(a.key, a.value) USING 'cat' AS (tkey, tvalue) FROM src a join src b diff --git a/ql/src/test/results/clientpositive/tez/explainanalyze_3.q.out b/ql/src/test/results/clientpositive/tez/explainprofile_3.q.out similarity index 92% rename from ql/src/test/results/clientpositive/tez/explainanalyze_3.q.out rename to ql/src/test/results/clientpositive/tez/explainprofile_3.q.out index dad999ab1a..c39c62f29f 100644 --- a/ql/src/test/results/clientpositive/tez/explainanalyze_3.q.out +++ b/ql/src/test/results/clientpositive/tez/explainprofile_3.q.out @@ -16,7 +16,7 @@ POSTHOOK: Input: default@srcpart@ds=2008-04-08/hr=12 POSTHOOK: Input: default@srcpart@ds=2008-04-09/hr=11 POSTHOOK: Input: default@srcpart@ds=2008-04-09/hr=12 POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze select key, value +PREHOOK: query: explain profile select key, value FROM srcpart LATERAL VIEW explode(array(1,2,3)) myTable AS myCol PREHOOK: type: QUERY PREHOOK: Input: default@srcpart @@ -25,7 +25,7 @@ PREHOOK: Input: default@srcpart@ds=2008-04-08/hr=12 PREHOOK: Input: default@srcpart@ds=2008-04-09/hr=11 PREHOOK: Input: default@srcpart@ds=2008-04-09/hr=12 PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze select key, value +POSTHOOK: query: explain profile select key, value FROM srcpart LATERAL VIEW explode(array(1,2,3)) myTable AS myCol POSTHOOK: type: QUERY POSTHOOK: Input: default@srcpart @@ -64,10 +64,10 @@ PREHOOK: Input: database:default POSTHOOK: query: show tables POSTHOOK: type: SHOWTABLES POSTHOOK: Input: database:default -PREHOOK: query: explain analyze show tables +PREHOOK: query: explain profile show tables PREHOOK: type: SHOWTABLES PREHOOK: Input: database:default -POSTHOOK: query: explain analyze show tables +POSTHOOK: query: explain profile show tables POSTHOOK: type: SHOWTABLES POSTHOOK: Input: database:default Stage-1 @@ -109,10 +109,10 @@ PREHOOK: Input: database:newdb POSTHOOK: query: describe database extended newDB POSTHOOK: type: DESCDATABASE POSTHOOK: Input: database:newdb -PREHOOK: query: explain analyze describe database extended newDB +PREHOOK: query: explain profile describe database extended newDB PREHOOK: type: DESCDATABASE PREHOOK: Input: database:newdb -POSTHOOK: query: explain analyze describe database extended newDB +POSTHOOK: query: explain profile describe database extended newDB POSTHOOK: type: DESCDATABASE POSTHOOK: Input: database:newdb Stage-1 @@ -134,10 +134,10 @@ PREHOOK: Input: database:newdb POSTHOOK: query: use newDB POSTHOOK: type: SWITCHDATABASE POSTHOOK: Input: database:newdb -PREHOOK: query: explain analyze use newDB +PREHOOK: query: explain profile use newDB PREHOOK: type: SWITCHDATABASE PREHOOK: Input: database:newdb -POSTHOOK: query: explain analyze use newDB +POSTHOOK: query: explain profile use newDB POSTHOOK: type: SWITCHDATABASE POSTHOOK: Input: database:newdb Stage-0 @@ -165,11 +165,11 @@ POSTHOOK: query: alter table tab_n2 rename to newName POSTHOOK: type: ALTERTABLE_RENAME POSTHOOK: Input: newdb@tab_n2 POSTHOOK: Output: newdb@tab_n2 -PREHOOK: query: explain analyze alter table tab_n2 rename to newName +PREHOOK: query: explain profile alter table tab_n2 rename to newName PREHOOK: type: ALTERTABLE_RENAME PREHOOK: Input: newdb@tab_n2 PREHOOK: Output: newdb@tab_n2 -POSTHOOK: query: explain analyze alter table tab_n2 rename to newName +POSTHOOK: query: explain profile alter table tab_n2 rename to newName POSTHOOK: type: ALTERTABLE_RENAME POSTHOOK: Input: newdb@tab_n2 POSTHOOK: Output: newdb@tab_n2 @@ -184,11 +184,11 @@ POSTHOOK: query: drop table tab_n2 POSTHOOK: type: DROPTABLE POSTHOOK: Input: newdb@tab_n2 POSTHOOK: Output: newdb@tab_n2 -PREHOOK: query: explain analyze drop table tab_n2 +PREHOOK: query: explain profile drop table tab_n2 PREHOOK: type: DROPTABLE PREHOOK: Input: newdb@tab_n2 PREHOOK: Output: newdb@tab_n2 -POSTHOOK: query: explain analyze drop table tab_n2 +POSTHOOK: query: explain profile drop table tab_n2 POSTHOOK: type: DROPTABLE POSTHOOK: Input: newdb@tab_n2 POSTHOOK: Output: newdb@tab_n2 @@ -209,10 +209,10 @@ PREHOOK: Input: database:default POSTHOOK: query: use default POSTHOOK: type: SWITCHDATABASE POSTHOOK: Input: database:default -PREHOOK: query: explain analyze use default +PREHOOK: query: explain profile use default PREHOOK: type: SWITCHDATABASE PREHOOK: Input: database:default -POSTHOOK: query: explain analyze use default +POSTHOOK: query: explain profile use default POSTHOOK: type: SWITCHDATABASE POSTHOOK: Input: database:default Stage-0 @@ -256,11 +256,11 @@ POSTHOOK: query: analyze table src_stats compute statistics POSTHOOK: type: QUERY POSTHOOK: Input: default@src_stats POSTHOOK: Output: default@src_stats -PREHOOK: query: explain analyze analyze table src_stats compute statistics +PREHOOK: query: explain profile analyze table src_stats compute statistics PREHOOK: type: QUERY PREHOOK: Input: default@src_stats PREHOOK: Output: default@src_stats -POSTHOOK: query: explain analyze analyze table src_stats compute statistics +POSTHOOK: query: explain profile analyze table src_stats compute statistics POSTHOOK: type: QUERY POSTHOOK: Input: default@src_stats POSTHOOK: Output: default@src_stats @@ -280,12 +280,12 @@ POSTHOOK: type: ANALYZE_TABLE POSTHOOK: Input: default@src_stats POSTHOOK: Output: default@src_stats POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze analyze table src_stats compute statistics for columns +PREHOOK: query: explain profile analyze table src_stats compute statistics for columns PREHOOK: type: ANALYZE_TABLE PREHOOK: Input: default@src_stats PREHOOK: Output: default@src_stats PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze analyze table src_stats compute statistics for columns +POSTHOOK: query: explain profile analyze table src_stats compute statistics for columns POSTHOOK: type: ANALYZE_TABLE POSTHOOK: Input: default@src_stats POSTHOOK: Output: default@src_stats @@ -313,11 +313,11 @@ PREHOOK: Output: database:default POSTHOOK: query: CREATE TEMPORARY MACRO SIGMOID (x DOUBLE) 1.0 / (1.0 + EXP(-x)) POSTHOOK: type: CREATEMACRO POSTHOOK: Output: database:default -PREHOOK: query: explain analyze +PREHOOK: query: explain profile CREATE TEMPORARY MACRO SIGMOID (x DOUBLE) 1.0 / (1.0 + EXP(-x)) PREHOOK: type: CREATEMACRO PREHOOK: Output: database:default -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile CREATE TEMPORARY MACRO SIGMOID (x DOUBLE) 1.0 / (1.0 + EXP(-x)) POSTHOOK: type: CREATEMACRO POSTHOOK: Output: database:default @@ -338,11 +338,11 @@ POSTHOOK: query: SELECT SIGMOID(2) FROM src LIMIT 1 POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze SELECT SIGMOID(2) FROM src LIMIT 1 +PREHOOK: query: explain profile SELECT SIGMOID(2) FROM src LIMIT 1 PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze SELECT SIGMOID(2) FROM src LIMIT 1 +POSTHOOK: query: explain profile SELECT SIGMOID(2) FROM src LIMIT 1 POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### @@ -363,10 +363,10 @@ PREHOOK: Output: database:default POSTHOOK: query: DROP TEMPORARY MACRO SIGMOID POSTHOOK: type: DROPMACRO POSTHOOK: Output: database:default -PREHOOK: query: explain analyze DROP TEMPORARY MACRO SIGMOID +PREHOOK: query: explain profile DROP TEMPORARY MACRO SIGMOID PREHOOK: type: DROPMACRO PREHOOK: Output: database:default -POSTHOOK: query: explain analyze DROP TEMPORARY MACRO SIGMOID +POSTHOOK: query: explain profile DROP TEMPORARY MACRO SIGMOID POSTHOOK: type: DROPMACRO POSTHOOK: Output: database:default Stage-0 @@ -388,12 +388,12 @@ POSTHOOK: type: CREATETABLE_AS_SELECT POSTHOOK: Input: default@src POSTHOOK: Output: database:default POSTHOOK: Output: default@src_autho_test_n4 -PREHOOK: query: explain analyze create table src_autho_test_n4 as select * from src +PREHOOK: query: explain profile create table src_autho_test_n4 as select * from src PREHOOK: type: CREATETABLE_AS_SELECT PREHOOK: Input: default@src PREHOOK: Output: database:default PREHOOK: Output: default@src_autho_test_n4 -POSTHOOK: query: explain analyze create table src_autho_test_n4 as select * from src +POSTHOOK: query: explain profile create table src_autho_test_n4 as select * from src POSTHOOK: type: CREATETABLE_AS_SELECT POSTHOOK: Input: default@src POSTHOOK: Output: database:default @@ -447,10 +447,10 @@ PREHOOK: Output: default@src_autho_test_n4 POSTHOOK: query: grant select on table src_autho_test_n4 to user hive_test_user POSTHOOK: type: GRANT_PRIVILEGE POSTHOOK: Output: default@src_autho_test_n4 -PREHOOK: query: explain analyze grant select on table src_autho_test_n4 to user hive_test_user +PREHOOK: query: explain profile grant select on table src_autho_test_n4 to user hive_test_user PREHOOK: type: GRANT_PRIVILEGE PREHOOK: Output: default@src_autho_test_n4 -POSTHOOK: query: explain analyze grant select on table src_autho_test_n4 to user hive_test_user +POSTHOOK: query: explain profile grant select on table src_autho_test_n4 to user hive_test_user POSTHOOK: type: GRANT_PRIVILEGE POSTHOOK: Output: default@src_autho_test_n4 Stage-0 @@ -466,9 +466,9 @@ PREHOOK: query: show grant user hive_test_user on table src_autho_test_n4 PREHOOK: type: SHOW_GRANT POSTHOOK: query: show grant user hive_test_user on table src_autho_test_n4 POSTHOOK: type: SHOW_GRANT -PREHOOK: query: explain analyze show grant user hive_test_user on table src_autho_test_n4 +PREHOOK: query: explain profile show grant user hive_test_user on table src_autho_test_n4 PREHOOK: type: SHOW_GRANT -POSTHOOK: query: explain analyze show grant user hive_test_user on table src_autho_test_n4 +POSTHOOK: query: explain profile show grant user hive_test_user on table src_autho_test_n4 POSTHOOK: type: SHOW_GRANT Stage-1 Fetch Operator @@ -480,9 +480,9 @@ PREHOOK: query: show grant user hive_test_user on table src_autho_test_n4(key) PREHOOK: type: SHOW_GRANT POSTHOOK: query: show grant user hive_test_user on table src_autho_test_n4(key) POSTHOOK: type: SHOW_GRANT -PREHOOK: query: explain analyze show grant user hive_test_user on table src_autho_test_n4(key) +PREHOOK: query: explain profile show grant user hive_test_user on table src_autho_test_n4(key) PREHOOK: type: SHOW_GRANT -POSTHOOK: query: explain analyze show grant user hive_test_user on table src_autho_test_n4(key) +POSTHOOK: query: explain profile show grant user hive_test_user on table src_autho_test_n4(key) POSTHOOK: type: SHOW_GRANT Stage-1 Fetch Operator @@ -524,10 +524,10 @@ PREHOOK: Output: default@src_autho_test_n4 POSTHOOK: query: revoke select on table src_autho_test_n4 from user hive_test_user POSTHOOK: type: REVOKE_PRIVILEGE POSTHOOK: Output: default@src_autho_test_n4 -PREHOOK: query: explain analyze revoke select on table src_autho_test_n4 from user hive_test_user +PREHOOK: query: explain profile revoke select on table src_autho_test_n4 from user hive_test_user PREHOOK: type: REVOKE_PRIVILEGE PREHOOK: Output: default@src_autho_test_n4 -POSTHOOK: query: explain analyze revoke select on table src_autho_test_n4 from user hive_test_user +POSTHOOK: query: explain profile revoke select on table src_autho_test_n4 from user hive_test_user POSTHOOK: type: REVOKE_PRIVILEGE POSTHOOK: Output: default@src_autho_test_n4 Stage-0 @@ -539,10 +539,10 @@ PREHOOK: Output: default@src_autho_test_n4 POSTHOOK: query: grant select(key) on table src_autho_test_n4 to user hive_test_user POSTHOOK: type: GRANT_PRIVILEGE POSTHOOK: Output: default@src_autho_test_n4 -PREHOOK: query: explain analyze grant select(key) on table src_autho_test_n4 to user hive_test_user +PREHOOK: query: explain profile grant select(key) on table src_autho_test_n4 to user hive_test_user PREHOOK: type: GRANT_PRIVILEGE PREHOOK: Output: default@src_autho_test_n4 -POSTHOOK: query: explain analyze grant select(key) on table src_autho_test_n4 to user hive_test_user +POSTHOOK: query: explain profile grant select(key) on table src_autho_test_n4 to user hive_test_user POSTHOOK: type: GRANT_PRIVILEGE POSTHOOK: Output: default@src_autho_test_n4 Stage-0 @@ -554,10 +554,10 @@ PREHOOK: Output: default@src_autho_test_n4 POSTHOOK: query: revoke select(key) on table src_autho_test_n4 from user hive_test_user POSTHOOK: type: REVOKE_PRIVILEGE POSTHOOK: Output: default@src_autho_test_n4 -PREHOOK: query: explain analyze revoke select(key) on table src_autho_test_n4 from user hive_test_user +PREHOOK: query: explain profile revoke select(key) on table src_autho_test_n4 from user hive_test_user PREHOOK: type: REVOKE_PRIVILEGE PREHOOK: Output: default@src_autho_test_n4 -POSTHOOK: query: explain analyze revoke select(key) on table src_autho_test_n4 from user hive_test_user +POSTHOOK: query: explain profile revoke select(key) on table src_autho_test_n4 from user hive_test_user POSTHOOK: type: REVOKE_PRIVILEGE POSTHOOK: Output: default@src_autho_test_n4 Stage-0 @@ -567,10 +567,10 @@ PREHOOK: query: create role sRc_roLE PREHOOK: type: CREATEROLE POSTHOOK: query: create role sRc_roLE POSTHOOK: type: CREATEROLE -PREHOOK: query: explain analyze +PREHOOK: query: explain profile create role sRc_roLE PREHOOK: type: CREATEROLE -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile create role sRc_roLE POSTHOOK: type: CREATEROLE Stage-0 @@ -584,10 +584,10 @@ PREHOOK: query: grant role sRc_roLE to user hive_test_user PREHOOK: type: GRANT_ROLE POSTHOOK: query: grant role sRc_roLE to user hive_test_user POSTHOOK: type: GRANT_ROLE -PREHOOK: query: explain analyze +PREHOOK: query: explain profile grant role sRc_roLE to user hive_test_user PREHOOK: type: GRANT_ROLE -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile grant role sRc_roLE to user hive_test_user POSTHOOK: type: GRANT_ROLE Stage-0 @@ -601,9 +601,9 @@ PREHOOK: query: show role grant user hive_test_user PREHOOK: type: SHOW_ROLE_GRANT POSTHOOK: query: show role grant user hive_test_user POSTHOOK: type: SHOW_ROLE_GRANT -PREHOOK: query: explain analyze show role grant user hive_test_user +PREHOOK: query: explain profile show role grant user hive_test_user PREHOOK: type: SHOW_ROLE_GRANT -POSTHOOK: query: explain analyze show role grant user hive_test_user +POSTHOOK: query: explain profile show role grant user hive_test_user POSTHOOK: type: SHOW_ROLE_GRANT Stage-1 Fetch Operator @@ -615,9 +615,9 @@ PREHOOK: query: drop role sRc_roLE PREHOOK: type: DROPROLE POSTHOOK: query: drop role sRc_roLE POSTHOOK: type: DROPROLE -PREHOOK: query: explain analyze drop role sRc_roLE +PREHOOK: query: explain profile drop role sRc_roLE PREHOOK: type: DROPROLE -POSTHOOK: query: explain analyze drop role sRc_roLE +POSTHOOK: query: explain profile drop role sRc_roLE POSTHOOK: type: DROPROLE Stage-0 Drop Role{"name:":"sRc_roLE"} @@ -638,9 +638,9 @@ PREHOOK: query: drop view v_n5 PREHOOK: type: DROPVIEW POSTHOOK: query: drop view v_n5 POSTHOOK: type: DROPVIEW -PREHOOK: query: explain analyze drop view v_n5 +PREHOOK: query: explain profile drop view v_n5 PREHOOK: type: DROPVIEW -POSTHOOK: query: explain analyze drop view v_n5 +POSTHOOK: query: explain profile drop view v_n5 POSTHOOK: type: DROPVIEW Stage-0 Drop View{"view name:":"v_n5"} @@ -657,13 +657,13 @@ POSTHOOK: type: CREATEVIEW POSTHOOK: Input: default@src POSTHOOK: Output: database:default POSTHOOK: Output: default@v_n5 -PREHOOK: query: explain analyze create view v_n5 as with cte as (select * from src order by key limit 5) +PREHOOK: query: explain profile create view v_n5 as with cte as (select * from src order by key limit 5) select * from cte PREHOOK: type: CREATEVIEW PREHOOK: Input: default@src PREHOOK: Output: database:default PREHOOK: Output: default@v_n5 -POSTHOOK: query: explain analyze create view v_n5 as with cte as (select * from src order by key limit 5) +POSTHOOK: query: explain profile create view v_n5 as with cte as (select * from src order by key limit 5) select * from cte POSTHOOK: type: CREATEVIEW POSTHOOK: Input: default@src @@ -684,12 +684,12 @@ select * from cte POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze with cte as (select * from src order by key limit 5) +PREHOOK: query: explain profile with cte as (select * from src order by key limit 5) select * from cte PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze with cte as (select * from src order by key limit 5) +POSTHOOK: query: explain profile with cte as (select * from src order by key limit 5) select * from cte POSTHOOK: type: QUERY POSTHOOK: Input: default@src @@ -742,11 +742,11 @@ POSTHOOK: query: insert overwrite table orc_merge5_n1 select userid,string1,subt POSTHOOK: type: QUERY POSTHOOK: Input: default@orc_merge5_n1 POSTHOOK: Output: default@orc_merge5_n1 -PREHOOK: query: explain analyze insert overwrite table orc_merge5_n1 select userid,string1,subtype,decimal1,ts from orc_merge5_n1 where userid<=13 +PREHOOK: query: explain profile insert overwrite table orc_merge5_n1 select userid,string1,subtype,decimal1,ts from orc_merge5_n1 where userid<=13 PREHOOK: type: QUERY PREHOOK: Input: default@orc_merge5_n1 PREHOOK: Output: default@orc_merge5_n1 -POSTHOOK: query: explain analyze insert overwrite table orc_merge5_n1 select userid,string1,subtype,decimal1,ts from orc_merge5_n1 where userid<=13 +POSTHOOK: query: explain profile insert overwrite table orc_merge5_n1 select userid,string1,subtype,decimal1,ts from orc_merge5_n1 where userid<=13 POSTHOOK: type: QUERY POSTHOOK: Input: default@orc_merge5_n1 POSTHOOK: Output: default@orc_merge5_n1 @@ -927,7 +927,7 @@ POSTHOOK: Input: default@tab_n2@ds=2008-04-08 POSTHOOK: Input: default@tab_part_n3 POSTHOOK: Input: default@tab_part_n3@ds=2008-04-08 POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select a.key, a.value, b.value from tab_n2 a join tab_part_n3 b on a.key = b.key PREHOOK: type: QUERY @@ -936,7 +936,7 @@ PREHOOK: Input: default@tab_n2@ds=2008-04-08 PREHOOK: Input: default@tab_part_n3 PREHOOK: Input: default@tab_part_n3@ds=2008-04-08 PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select a.key, a.value, b.value from tab_n2 a join tab_part_n3 b on a.key = b.key POSTHOOK: type: QUERY diff --git a/ql/src/test/results/clientpositive/tez/explainanalyze_4.q.out b/ql/src/test/results/clientpositive/tez/explainprofile_4.q.out similarity index 98% rename from ql/src/test/results/clientpositive/tez/explainanalyze_4.q.out rename to ql/src/test/results/clientpositive/tez/explainprofile_4.q.out index 3de34b2df6..e28fc6c8c8 100644 --- a/ql/src/test/results/clientpositive/tez/explainanalyze_4.q.out +++ b/ql/src/test/results/clientpositive/tez/explainprofile_4.q.out @@ -16,7 +16,7 @@ order by a.cint POSTHOOK: type: QUERY POSTHOOK: Input: default@alltypesorc POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select * from alltypesorc a join alltypesorc b on a.cint = b.cint @@ -26,7 +26,7 @@ order by a.cint PREHOOK: type: QUERY PREHOOK: Input: default@alltypesorc PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select * from alltypesorc a join alltypesorc b on a.cint = b.cint @@ -117,7 +117,7 @@ where POSTHOOK: type: QUERY POSTHOOK: Input: default@alltypesorc POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select count(*) from alltypesorc a join alltypesorc b on a.cint = b.cint @@ -126,7 +126,7 @@ where PREHOOK: type: QUERY PREHOOK: Input: default@alltypesorc PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select count(*) from alltypesorc a join alltypesorc b on a.cint = b.cint @@ -209,7 +209,7 @@ order by c1 POSTHOOK: type: QUERY POSTHOOK: Input: default@alltypesorc POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select a.csmallint, count(*) c1 from alltypesorc a join alltypesorc b on a.cint = b.cint @@ -220,7 +220,7 @@ order by c1 PREHOOK: type: QUERY PREHOOK: Input: default@alltypesorc PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select a.csmallint, count(*) c1 from alltypesorc a join alltypesorc b on a.cint = b.cint @@ -317,7 +317,7 @@ order by a.cint POSTHOOK: type: QUERY POSTHOOK: Input: default@alltypesorc POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select * from alltypesorc a join alltypesorc b on a.cint = b.cint @@ -327,7 +327,7 @@ order by a.cint PREHOOK: type: QUERY PREHOOK: Input: default@alltypesorc PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select * from alltypesorc a join alltypesorc b on a.cint = b.cint @@ -418,7 +418,7 @@ where POSTHOOK: type: QUERY POSTHOOK: Input: default@alltypesorc POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select count(*) from alltypesorc a join alltypesorc b on a.cint = b.cint @@ -427,7 +427,7 @@ where PREHOOK: type: QUERY PREHOOK: Input: default@alltypesorc PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select count(*) from alltypesorc a join alltypesorc b on a.cint = b.cint @@ -510,7 +510,7 @@ order by c1 POSTHOOK: type: QUERY POSTHOOK: Input: default@alltypesorc POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze +PREHOOK: query: explain profile select a.csmallint, count(*) c1 from alltypesorc a join alltypesorc b on a.cint = b.cint @@ -521,7 +521,7 @@ order by c1 PREHOOK: type: QUERY PREHOOK: Input: default@alltypesorc PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze +POSTHOOK: query: explain profile select a.csmallint, count(*) c1 from alltypesorc a join alltypesorc b on a.cint = b.cint diff --git a/ql/src/test/results/clientpositive/tez/explainanalyze_5.q.out b/ql/src/test/results/clientpositive/tez/explainprofile_5.q.out similarity index 96% rename from ql/src/test/results/clientpositive/tez/explainanalyze_5.q.out rename to ql/src/test/results/clientpositive/tez/explainprofile_5.q.out index 5088a3d155..e81b3ad8be 100644 --- a/ql/src/test/results/clientpositive/tez/explainanalyze_5.q.out +++ b/ql/src/test/results/clientpositive/tez/explainprofile_5.q.out @@ -22,11 +22,11 @@ POSTHOOK: query: analyze table src_stats_n0 compute statistics POSTHOOK: type: QUERY POSTHOOK: Input: default@src_stats_n0 POSTHOOK: Output: default@src_stats_n0 -PREHOOK: query: explain analyze analyze table src_stats_n0 compute statistics +PREHOOK: query: explain profile analyze table src_stats_n0 compute statistics PREHOOK: type: QUERY PREHOOK: Input: default@src_stats_n0 PREHOOK: Output: default@src_stats_n0 -POSTHOOK: query: explain analyze analyze table src_stats_n0 compute statistics +POSTHOOK: query: explain profile analyze table src_stats_n0 compute statistics POSTHOOK: type: QUERY POSTHOOK: Input: default@src_stats_n0 POSTHOOK: Output: default@src_stats_n0 @@ -46,12 +46,12 @@ POSTHOOK: type: ANALYZE_TABLE POSTHOOK: Input: default@src_stats_n0 POSTHOOK: Output: default@src_stats_n0 POSTHOOK: Output: hdfs://### HDFS PATH ### -PREHOOK: query: explain analyze analyze table src_stats_n0 compute statistics for columns +PREHOOK: query: explain profile analyze table src_stats_n0 compute statistics for columns PREHOOK: type: ANALYZE_TABLE PREHOOK: Input: default@src_stats_n0 PREHOOK: Output: default@src_stats_n0 PREHOOK: Output: hdfs://### HDFS PATH ### -POSTHOOK: query: explain analyze analyze table src_stats_n0 compute statistics for columns +POSTHOOK: query: explain profile analyze table src_stats_n0 compute statistics for columns POSTHOOK: type: ANALYZE_TABLE POSTHOOK: Input: default@src_stats_n0 POSTHOOK: Output: default@src_stats_n0 @@ -95,12 +95,12 @@ POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Input: default@src1 POSTHOOK: Output: default@src_multi2_n7 -PREHOOK: query: explain analyze insert overwrite table src_multi2_n7 select subq.key, src.value from (select * from src union select * from src1)subq join src on subq.key=src.key +PREHOOK: query: explain profile insert overwrite table src_multi2_n7 select subq.key, src.value from (select * from src union select * from src1)subq join src on subq.key=src.key PREHOOK: type: QUERY PREHOOK: Input: default@src PREHOOK: Input: default@src1 PREHOOK: Output: default@src_multi2_n7 -POSTHOOK: query: explain analyze insert overwrite table src_multi2_n7 select subq.key, src.value from (select * from src union select * from src1)subq join src on subq.key=src.key +POSTHOOK: query: explain profile insert overwrite table src_multi2_n7 select subq.key, src.value from (select * from src union select * from src1)subq join src on subq.key=src.key POSTHOOK: type: QUERY POSTHOOK: Input: default@src POSTHOOK: Input: default@src1 @@ -293,11 +293,11 @@ POSTHOOK: query: update acid_uami_n2 set de = 3.14 where de = 109.23 or de = 119 POSTHOOK: type: QUERY POSTHOOK: Input: default@acid_uami_n2 POSTHOOK: Output: default@acid_uami_n2 -PREHOOK: query: explain analyze update acid_uami_n2 set de = 3.14 where de = 109.23 or de = 119.23 +PREHOOK: query: explain profile update acid_uami_n2 set de = 3.14 where de = 109.23 or de = 119.23 PREHOOK: type: QUERY PREHOOK: Input: default@acid_uami_n2 PREHOOK: Output: default@acid_uami_n2 -POSTHOOK: query: explain analyze update acid_uami_n2 set de = 3.14 where de = 109.23 or de = 119.23 +POSTHOOK: query: explain profile update acid_uami_n2 set de = 3.14 where de = 109.23 or de = 119.23 POSTHOOK: type: QUERY POSTHOOK: Input: default@acid_uami_n2 POSTHOOK: Output: default@acid_uami_n2 @@ -410,11 +410,11 @@ POSTHOOK: query: delete from acid_dot_n0 where cint < -1070551679 POSTHOOK: type: QUERY POSTHOOK: Input: default@acid_dot_n0 POSTHOOK: Output: default@acid_dot_n0 -PREHOOK: query: explain analyze delete from acid_dot_n0 where cint < -1070551679 +PREHOOK: query: explain profile delete from acid_dot_n0 where cint < -1070551679 PREHOOK: type: QUERY PREHOOK: Input: default@acid_dot_n0 PREHOOK: Output: default@acid_dot_n0 -POSTHOOK: query: explain analyze delete from acid_dot_n0 where cint < -1070551679 +POSTHOOK: query: explain profile delete from acid_dot_n0 where cint < -1070551679 POSTHOOK: type: QUERY POSTHOOK: Input: default@acid_dot_n0 POSTHOOK: Output: default@acid_dot_n0