13
randomr
7y

When the guy with his master's who's job you were told you weren't qualified for performed the following all in one query:
1. A massive many to many join on a 4 million row table.....to itself on in inner query through a linked server.
2. Decides to try and join this massive inner query (see step 1) to another table on a second many to many join.
3. Writes a function for month. Yes instead of month(literallyadate)

Then this guy emails me to ask if I can optimize it because we yelled at him for trying to insert 216 GB of data into a table (again on a massive many to many joined disaster). We told him if a query was taking more than 40 minutes we needed to see it.

I regret saying that now...should have just bought more space ;)

Comments
  • 1
    Wow! 🤔
  • 1
    Dang! I felt bad for writing a function that took almost 20 seconds to find and update specific references across an entire ERP database. Thanks for helping me ameliorate my impostor syndrome.
  • 2
    @ultraweaklisk Just finished upgrading their department to the new report server and helped them go through all their stored procedures for jobs they ran. Went from 4200 minutes of runtime per day to 2100.
Add Comment