Skip to content

Instantly share code, notes, and snippets.

@NeerajBhadani
Created May 25, 2020 15:21
Show Gist options
  • Save NeerajBhadani/8832310734678e12e4aa9e0ef30164ff to your computer and use it in GitHub Desktop.
Save NeerajBhadani/8832310734678e12e4aa9e0ef30164ff to your computer and use it in GitHub Desktop.
Define custom window Specification
val winSpec = Window.partitionBy("depName")
.orderBy("salary").rowsBetween(-1, 1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment