2008/10/31 Moon's Father <[EMAIL PROTECTED]> > *A prepared statement is also global to the connection. If you create a > prepared statement within a stored routine, it is not deallocated when the > stored routine ends. * > > Then I don't know how to deallocate the memory used by prepare statement > within procedure? >
The memory will be de-allocated when you disconnect that session, there is no need to worry about it's memory usage. This statement simply means that if you call a method twice, which uses the same prepared statement, it will on need to be re-prepared, and hence you will see an improvement in speed.