> Once you know window functions, you risk putting them all over the place
Agreed.
A few years of writing expressive, powerful, performant SQL in big blocks will really change your mental model of data across _all_ languages.
I highly recommend a deep dive into the relational world, and I feel super grateful for the SQL-focused job I held previously. Brought those lessons back with me to both FP and OO.