You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2022/06/09 16:23:08 UTC

[GitHub] [spark] huaxingao commented on a diff in pull request #36820: [SPARK-39428][DOC] Use code block for Coalesce-Hints-for-SQL-Queries

huaxingao commented on code in PR #36820:
URL: https://github.com/apache/spark/pull/36820#discussion_r893717557


##########
docs/sql-performance-tuning.md:
##########
@@ -222,17 +222,19 @@ parameter. The "REPARTITION" hint has a partition number, columns, or both/neith
 The "REPARTITION_BY_RANGE" hint must have column names and a partition number is optional. The "REBALANCE"
 hint has an initial partition number, columns, or both/neither of them as parameters.
 
-    SELECT /*+ COALESCE(3) */ * FROM t
-    SELECT /*+ REPARTITION(3) */ * FROM t
-    SELECT /*+ REPARTITION(c) */ * FROM t
-    SELECT /*+ REPARTITION(3, c) */ * FROM t
-    SELECT /*+ REPARTITION */ * FROM t
-    SELECT /*+ REPARTITION_BY_RANGE(c) */ * FROM t
-    SELECT /*+ REPARTITION_BY_RANGE(3, c) */ * FROM t
-    SELECT /*+ REBALANCE */ * FROM t
-    SELECT /*+ REBALANCE(3) */ * FROM t
-    SELECT /*+ REBALANCE(c) */ * FROM t
-    SELECT /*+ REBALANCE(3, c) */ * FROM t
+```sql
+SELECT /*+ COALESCE(3) */ * FROM t
+SELECT /*+ REPARTITION(3) */ * FROM t
+SELECT /*+ REPARTITION(c) */ * FROM t
+SELECT /*+ REPARTITION(3, c) */ * FROM t
+SELECT /*+ REPARTITION */ * FROM t
+SELECT /*+ REPARTITION_BY_RANGE(c) */ * FROM t
+SELECT /*+ REPARTITION_BY_RANGE(3, c) */ * FROM t
+SELECT /*+ REBALANCE */ * FROM t
+SELECT /*+ REBALANCE(3) */ * FROM t
+SELECT /*+ REBALANCE(c) */ * FROM t
+SELECT /*+ REBALANCE(3, c) */ * FROM t

Review Comment:
   nit: Could you add `;` to the end of each of these SQL statements?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org