Guest User

Untitled

a guest
Aug 21st, 2018
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.17 KB | None | 0 0
  1. # Get count by status from orders
  2. orders.groupBy('order_status').count().show()
  3. orders.groupBy('order_status'). \
  4. agg(count('order_status').alias('status_count')). \
  5. show()
Add Comment
Please, Sign In to add comment