Koen Verbeeck looks at a bit of non-standard syntax:
Once upon a time I had a series about some cool stuff in Snowflake: features in their SQL dialect that were not available in the T-SQL dialect at the time (and some still aren’t). I followed up with some posts about interesting Fabric features (some of them are more “ironic” in nature as they describe extremely basic features who were originally missing in Fabric, like folders).
Recently I started working with Databricks on a project, and I mainly have to use the serverless SQL endpoint. Like Snowflake, Databricks also has a pretty amazing SQL dialect. In this blog post, I’m going to talk about one of my favorite new additions to the world of window functions: QUALIFY.
QUALIFY has been around since the Teradata days and it filters window functions in your SELECT statement. That makes it pretty useful, as it means you don’t need common table expressions or sub-queries to filter the results of a SQL query using a window function, like getting records where the RANK() is in the top 3.
Leave a Comment