Using Window Functions Instead of Aggregate Functions in SQL CASE Statements on October 08, 2026 SQL +