LuciferYang commented on code in PR #42717:
URL: https://github.com/apache/spark/pull/42717#discussion_r1308261175


##########
python/pyspark/sql/functions.py:
##########
@@ -670,50 +671,74 @@ def asc(col: "ColumnOrName") -> Column:
     Parameters
     ----------
     col : :class:`~pyspark.sql.Column` or str
-        target column to sort by in the ascending order.
+        Target column to sort by in the ascending order.
 
     Returns
     -------
     :class:`~pyspark.sql.Column`
-        the column specifying the order.
+        The column specifying the sort order.
 
     Examples
     --------
-    Sort by the column 'id' in the descending order.
+    Example 1: Sort DataFrame by 'id' column in ascending order.
 
-    >>> df = spark.range(5)
-    >>> df = df.sort(desc("id"))

Review Comment:
   The original example is incorrect, it demonstrated a desc example within 
function asc.



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to