What does the LEAD() window function return when the offset goes beyond the last row of the partition?

SQL Data Analyst Hard

SQL Data Analyst — Hard

What does the LEAD() window function return when the offset goes beyond the last row of the partition?

Key points

  • LEAD() function returns NULL by default when offset exceeds partition
  • User-specified default value can be returned if provided
  • This behavior allows for flexibility in handling out-of-range offsets

Ready to go further?

Related questions