Please edit your post and fix the formatting using the </> button. You've lost indentation and syntax highlighting on both your Python code and SQL query. See Wiki - how to post code on this forum.
1 Like