Subject Re: [Firebird-Architect] Drop Database and Handles
Author Jim Starkey
Dimitry Sibiryakov wrote:

>On 29 Apr 2005 at 10:21, Jim Starkey wrote:
>
>
>
>>Steve Krueger has asked an interesting question: What happens to
>>database handles when DSQL executes a "drop database".
>>
>>
>
> Can't say about DSQL, but isc_drop_database() properly clean given
>database handle and all associated statement handles.
>
Yup. And if we didn't have "drop database" we wouldn't have a problem.

> Can a database be dropped when there is more than one connection to
>it? I don't think so. Or you are talking about another bug in Vulcan?
>
Worth thinking about. There are at least two ways to go. One is to
mark the database for deletion on last detachments. The other is to
throw an exception if somebody tries to drop a database in use, which
makes a certain amount of logical sense.

It was detected as a memory leak in ISQL, which simply abandons a
database handle after a "drop database" leaving all sorts of gook orphaned.