From: Economou, M. (G. C. Solutions)
<mat...@ae...> - 2000-07-11 19:48:03
|
Hello, I have a Perl script that takes a DN, attribute, and values to replace on the command line and executes the Net::LDAP::modify method with the specified arguments, e.g. (with error checking, binding, etc., elided): $modifydn = shift; $attribute = shift; foreach $arg (@ARGV) { push @values, $arg; } $result = $ldap -> modify (dn => $modifydn, replace => { $attribute => [ @values ] }); All in all, it's fairly simple (the only big hang up I had was figuring out that the "@values" part required square braces). My question regards type converting the @values list. If the attribute that is being added/replaced is an integer instead of a string, do I need to walk POSIX::strtol over @values, or will LDAP or the module Do The Right Thing? Kind regards, #\Matthew |