Performance optimization skill: Pre-Joining
I Problem introduction & solving The JOIN performance in SQL is a long-standing problem, especially when there are a lot of tables to be joined, the performance plummets dramatically. SQL adopts the HASH partition approach to handle JOINs, which first calculates the HASH values of the join keys and then traverses and compares the records with the same HASH values from two tables. The same computation steps are necessary for each JOIN. If the data volume is small compared to the size of memory, we can load the data into memory in advance and create the association using the in-memory pointer mechanism.
...