Hi -
I've just been preparing a package that handles 'any'
db specified by the user. The DBDs are not consistent.
I haven't tried LDAP, but here are a couple of thoughts:
1> try adding { AutoCommit => 0, } as the last param
to connect. This may _not_ work at all, it depends
on how your LDAP driver handles it. It's really a
mute point if you are only reading the db anyway.
2> explicity undef the handle after disconnect:
$dbh = undef;
3> check to see if you have the latest DBI and
LDAP DBD from CPAN.
Aloha => Beau.
-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:activeperl-admin@;listserv.ActiveState.com]On Behalf Of Mathias
Alt
Sent: Wednesday, October 16, 2002 11:39 PM
To: [EMAIL PROTECTED]
Subject: DBD::LDAP - there is no response
Hello,
I want to use DBD::LDAP to get some information from a LDAP-Server using a
SQL-statement. While executing my code there are some warnings I do not
understand. This is my output on the shell:
before execute
after execute
before finish
after finish
after disconnect
(in cleanup) Driver has not implemented DESTROY for DBI::st=HASH(0x2628fcc)
at testdb.pl line 0
(in cleanup) Driver has not implemented DESTROY for DBI::st=HASH(0x2628fcc)
at testdb.pl line 0
(in cleanup) Driver has not implemented the AutoCommit attribute at
C:/Perl/site/lib/DBD/LDAP.pm line 240, <DBFILE> line 2 during global
destruction.
And here my code (testdb.pl):
#!/usr/bin/perl -w
use DBI;
$dbh = DBI->connect("DBI:LDAP:dbase")
or die "Cannot connect as user: " . $DBI::errstr;
$sth = $dbh->prepare("select * from mytable")
or die "Cannot prepare: " . $dbh->errstr();
print "before execute\n";
$sth->execute() or die "Cannot execute: " . $sth->errstr();
print "after execute\n";
while(@row = $sth->fetchrow_array){
print "@row\n";
}
print "before finish\n";
$sth->finish();
print "after finish\n";
$dbh->disconnect();
print "after disconnect\n";
------
dbase.ldp:
10.x.xx.xxx;389:o=bxxx_xx,c=de
mytable:ou=uxxxx,ou=ixxxx::idontknow:::
--------
The "print" does not produce any output.
Can anybody help me?
Greetings from germany
Mathias Alt
--
+++ GMX - Mail, Messaging & more http://www.gmx.net +++
NEU: Mit GMX ins Internet. Rund um die Uhr f�r 1 ct/ Min. surfen!
_______________________________________________
ActivePerl mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
_______________________________________________
ActivePerl mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs