Scalability optimization: clean up the temp table as we go per table block.