Learned to code in SQL over the past few months. Working with a bit of code right now that I KNOW can be optimized, but unsure how. Googling it, I can't quite unite the logic of the online examples to what I'm working with in particular. In comes chatGPT...