Hello,
> Did you run ANALYZE on TEMP_TABLE after loading data and before running your query?
Nope, not yet. What will the effect be? The temp table is comparatively small compared to the main table (and has, yet,
noforeign keys).
> You're not doing a lot of deletes or updates in TEMP_TABLE at any point, are you?
Only one insert. The temp table gets created, used (hopefully, if I get this query to run faster, only once) and then
dropped.
Regards,
Flo