I have a critical situation where I need to generate a dynamic report ( Ie from the Client browser when the User clicks the report I need to fetch the values from the database) and display to the User.
This query is taking a long time app. 2 minutes, Since of the volume of records in the table and i am joining four tables. One of my friend is suggesting temporary table concept which will fetch the results fast.
Even in temporary table also, I need to do a select in order to insert the rows to that temp. table. So how does a temporary table increase the performace particularly in the case of dynamic report?