title: Should I use complex SQL queries or process results in the application?
body: <p>I am dealing with an application with huge SQL queries. They are so complex that when I finish understanding one I have already forgotten how it all started.</p>
  
  <p>I was wondering if it will be a good practice to pull more data from database and make the final query in my code, let's say, with Python. Am I nuts? Would it be that bad for performance?</p>
  
  <p>Note, results are huge too, I am talking about an ERP in production developed by other people.</p>