DEV Community

Ismail
Ismail

Posted on

SQL query optimization, 3 min to 0.5 sec

Today, I was working on an SQL query and managed to optimize it. Previously, it took almost three minutes to run, but after optimization, it now takes only 0.5 seconds.

To achieve this optimization, I converted some of the sub-queries into joins. This is because sub-queries tend to take a lot of time when dealing with large amounts of data.

Image description

Top comments (0)