disconnect the mysql object only when doing the file_close event
do not disconnect from mysql at every single query anymore