I have a query being compiled in a template but by the time it's run, it appears that the query module has lost it's connection to the DB:
Error Number: 2013
Lost connection to MySQL server during query
..query here...
Filename: modules/query/mod.query.php
Line Number: 181
Is there any way to extend the database connection period so this can be avoided?