Possible Duplicate:
using mysql_close()
Are mysql_close and pg_close required ?
In some script there aren’t… why ?
What happen if I don’t use its ?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
If you don’t call it, the socket connection to the database remains open for ~30 seconds in a wait state.
If you get lots and lots of people and you don’t somehow manage to reuse these zombie connections, your database might explode with a too many users error.
So in answer to your question: syntactically not required but it’s very poor practice not to include them.