Hi all, I am a new member on this list and after reading the posts from this list in the last few days, I don't even know if this is the apropriate place for asking questions about using mod_perl. If it is not, please tell me if there is another list which could be more useful for a mod_perl beginner.
I want to use the DBI module with mod_perl 2 with Perl 5.8.4, and for the moment... under Windows 2000. I have tried: In httpd.conf: PerlRequire [path]/preload.pl in preload.pl: use Apache::DBI(); use DBI (); DBI->install_driver("mysql"); ###Apache::DBI->connect_on_init("DBI:mysql:database=presa;host=localhost", "ODBC", undef, {PrintError =>1, RaiseError=>0, AutoCommit => 1}); in the GetCategories.pm module: ##use Apache::DBI; use DBI; my $dbh = ...; I have tried more combinations, but every time I get the following error in the logs: [Tue Dec 28 21:07:34 2004] [error] DBD::mysql::db prepare failed: handle 2 is owned by thread 265c564 not current thread 14ce78c (handles can't be shared between threads and your driver may need a CLONE method added) at f:/web/presa/modules/GetCategories.pm line 18.\n ----- So I have commented out the following line in preload.pl: ###Apache::DBI->connect_on_init("DBI:mysql:database=presa;host=localhost", "ODBC", undef, {PrintError =>1, RaiseError=>0, AutoCommit => 1}); And in GetCategories.pm I have used only: use DBI; my $dbh = ...; Well, in this case the script works, but I don't know if this way of using DBI is the best way. Thank you for any suggestion. Teddy -- Report problems: http://perl.apache.org/bugs/ Mail list info: http://perl.apache.org/maillist/modperl.html List etiquette: http://perl.apache.org/maillist/email-etiquette.html