> > By the way, the last call to fetchrow_array() (that returns
> > 'undef') implicitly calls finish() internally.

> I assume this is the same finish of the handle obtained from my
> prepare.  But because I have a reference to the handle holed away it
> is not really "finished" and that is why I am able to continue to use
> the prepared statement? Is this assumption correct?

I suspect you are mixing a couple of different concepts together,
although I can only what they are exactly.

As the DBI documentation mentions, the finish() method should more
accurately be called discard_pending_rows(). It does not actually do
very much - more a way of saying "I don't need any more information
from this handle."

That method is unrelated to Perl's reference counting which keeps track
of objects and their memory, and which you usually don't need to worry
about. If you keep a reference to the statement handle somewhere then
you can run execute() on it again, and when all the references are
gone Perl will do what it needs to do memory wise which *may* involve
calls to the underlying SQLite C API as needed.

-- 
Mark Lawrence
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to