viirya commented on a change in pull request #26496: [WIP][SPARK-29748][PYTHON][SQL] Remove Row field sorting in PySpark URL: https://github.com/apache/spark/pull/26496#discussion_r353508200
########## File path: python/pyspark/sql/types.py ########## @@ -1432,10 +1434,20 @@ class Row(tuple): ``key in row`` will search through row keys. - Row can be used to create a row object by using named arguments, - the fields will be sorted by names. It is not allowed to omit - a named argument to represent the value is None or missing. This should be - explicitly set to None in this case. + Row can be used to create a row object by using named arguments. + It is not allowed to omit a named argument to represent the value is + None or missing. This should be explicitly set to None in this case. + + NOTE: As of Spark 3.0.0, the Row field names are no longer sorted + alphabetically. To enable field sorting to create Rows compatible with + Spark 2.x, set the environment variable "PYSPARK_ROW_FIELD_SORTING_ENABLED" Review comment: I'm curious when this compatibility will be matter? If using Python >= 3.6 at Spark 3.0.0, do users need this compatibility? ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org