From: <CZa...@wi...> - 2002-03-26 20:29:25
|
Hello, can anyone help with the LDIF class. I'm am reading a ldif file and trying to place the contents into a DB, but I am getting errors and the modify updates are not being applied to the LDAP service. ERROR Message: modifytimestamp attribute has duplicate value. VALUE: at ldif_modify.pl line 20, <GEN1> chunk 1. CODE: #!/usr/bin/perl -w use Net::LDAP qw(:all); use Net::LDAP::Util qw(ldap_error_desc); use Net::LDAP::LDIF; $ldap = Net::LDAP->new('server.xyz.com', port => '389') || die "ERROR: $@"; $ldif = Net::LDAP::LDIF->new("out.ldif", "r") || die "$@"; while ( $entry = $ldif->read_entry ) { $r = $ldap->modify( $entry ); if ($r->code) { warn $entry->dn,"; ",$r->error; } else { printf "%s\n",ldap_error_desc($r->code); } } |