What do you want to save?
Add Code snippet
New code examples
-
Python 2021-11-08 13:54:10
Returns a new DataFrame sorted by the specified column(s)
# Returns a new DataFrame sorted by the specified column(s) df.sort(df.age.desc()).collect() # [Row(age=5, name=u'Bob'), Row(age=2, name=u'Alice')] df.sort("age", ascending=False).collect() # [Row(age=5, name=u'Bob'), Row(age=2, name=u'Alice')]... Add solution
Best helpers
Florian Huit
+5
Huggy Buggy
+5
Joyo
+5
ImMathan
+5
Anugram
+5
Vy32
+5
SOUMEN
+5
Nelsonic
+5
Csandreas1
+5
B_archer
+5
Horse
+5
Kraja
+5
Kd88
+5
Shahruz Raad
+5
Mick Daw
+5
Czlsws
+5
Daniel Cook
+5