On Thu, Oct 28, 2010 at 10:57:20PM -0500, Damon Courtney wrote: > You need to write a helper function to create the DB connection if it > doesn't already exist and then return it if it does. The reason you're > hitting this is because every time you request a page, you get a random > child process from Apache. You don't know which one you're going to > get, and it's unlikely you'll get the same one over and over again. > Once you create the DB handle the first time in the global scope, it > will remain in that Apache child, but you may get a different child > next time.
Thanks. I was suspecting something like this. Eventually, all of the children will have a ::db1 procedure, and all will be happy. I was afraid that I was causing some unnecessary thrashing, but I guess it's necessary after all. Happy Tcl'ing, Clif -- ... Clif Flynt ... http://www.cwflynt.com ... [email protected] ... .. Tcl/Tk: A Developer's Guide (2nd edition) - Morgan Kauffman .. .. 17'th Annual Tcl/Tk Conference: 2010, Oak Brook, IL USA .. ............. http://www.tcl.tk/community/tcl2010/ ............ --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
