 <p>The lifetime of a prepared statement is guaranteed to last for a given session. So if your session lasts an hour, the prepared statement will be valid for that hour. </p> <p>The following statement is taken from this <a href="http://www.theserverside.com/news/1365244/Why-Prepared-Statements-are-important-and-how-to-use-them-properly" rel="nofollow">link</a>:</p> <p><code>Normally, a prepared statement is associated with a single database connection. When the connection is closed, the preparedstatement is discarded.</code></p> <p>The keyword there is "normally". If you want to read about the exceptions, follow the link.</p>