After install DBD:mysql, perl still can"t connect to mysql

After install DBD:mysql, perl still can"t connect to mysql

am 25.07.2007 11:13:03 von Quoc Tuan

------=_NextPart_000_0078_01C7CED6.ADBDAA80
Content-Type: text/plain;
charset="iso-2022-jp"
Content-Transfer-Encoding: quoted-printable

hi,

I installed DBI, DBD:mysql, but when i use perl for connecting to mysql, =
some error has been occured.=20

install_driver(mysql) failed: Can't load =
'/usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi/auto /DBD/mysql/my=
sql.so' for module DBD::mysql: =
/usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi/auto/ DBD/mysql/mys=
ql.so: undefined symbol: __pure_virtual at =
/usr/lib/perl5/5.8.8/i386-linux-thread-multi/DynaLoader.pm line 230.
at (eval 4) line 3
Compilation failed in require at (eval 4) line 3.
Perhaps a required shared library or dll isn't installed where expected
at first.pl line 6

My perl page : first.pl
#!/usr/bin/perl -w
use CGI qw(:standard);
use CGI::Carp;
use DBI;
$conn =3D DBI->connect('DBI:mysql:db_asterisk','root','');

It always errors at $conn =3D =
DBI->connect('DBI:mysql:db_asterisk','root','')

Please guide me to install that perl can connect to mysql


Best regards
QTuan
------=_NextPart_000_0078_01C7CED6.ADBDAA80--

Re: After install DBD:mysql, perl still can"t connect to mysql

am 28.07.2007 17:22:23 von Patrick Galbraith

Quoc,

Hello!

Questions:

1. What OS are you using?
2. What version of mysql, and is it a binary distribution you obtained
from MySQL's download site?
3. What compile options did you use to build DBD::msyql?

I suspect that this is a mistmatch between you MySQL libraries being
built with a different compiler/flags that the binary was built with and
DBD::mysql being built by you with compiler flags of your own server.

regards,

Patrick


Quoc Tuan wrote:

>hi,
>
>I installed DBI, DBD:mysql, but when i use perl for connecting to mysql, some error has been occured.
>
>install_driver(mysql) failed: Can't load '/usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi/auto /DBD/mysql/mysql.so' for module DBD::mysql: /usr/lib/perl5/site_perl/5.8.8/i386-linux-thread-multi/auto/ DBD/mysql/mysql.so: undefined symbol: __pure_virtual at /usr/lib/perl5/5.8.8/i386-linux-thread-multi/DynaLoader.pm line 230.
> at (eval 4) line 3
>Compilation failed in require at (eval 4) line 3.
>Perhaps a required shared library or dll isn't installed where expected
> at first.pl line 6
>
>My perl page : first.pl
>#!/usr/bin/perl -w
>use CGI qw(:standard);
>use CGI::Carp;
>use DBI;
>$conn = DBI->connect('DBI:mysql:db_asterisk','root','');
>
>It always errors at $conn = DBI->connect('DBI:mysql:db_asterisk','root','')
>
>Please guide me to install that perl can connect to mysql
>
>
>Best regards
>QTuan
>
>


--
Patrick Galbraith, Senior Programmer
Grazr - Easy feed grazing and sharing
http://www.grazr.com

Satyam Eva Jayate - Truth Alone Triumphs
Mundaka Upanishad




--
MySQL Perl Mailing List
For list archives: http://lists.mysql.com/perl
To unsubscribe: http://lists.mysql.com/perl?unsub=gcdmp-msql-mysql-modules@m .gmane.org