I currently have a script running and didn’t think it would take so long to run, the script is modifying a temporary table.
I know that temporary tables only exist for the current session, but is there anyway to see the data they hold from outside the session?
Reason is that I want to know how long my script is going to keep running for, if I could see the temporary data then I’d be able to figure it out.
There’s no easy way of doing this I’m afraid.
Temporary tables will be stored in your mysqld’s designated temp directory (usually /tmp) and you’ll see a set of tables something like:
That’s a normal set of MyISAM tables defining (in order above) structure, data and index.
This is horribly hacky but I suspect you could copy these tables out into say your
testschema, run a repair on the table and then view it’s contents.If you can gauge the process by the size of the temp table then that could well be a simpler way of analysing what’s going on.