Softerra LDAP Administrator HelpShow AllHide All

RANDOM_STRING

The function generates a random string of a specified length.

Syntax

RANDOM_STRING (string_length)

Arguments

string_lengt - specifies the length of the generated string.

Examples

The following example modifies the userPassword attribute of all users in CN=Terminated Employees,DC=company and set it to the value of six random characters.

UPDATE "CN=Terminated Employees,DC=company" 
SET $userPassword=RANDOM_STRING(6);
WHERE $objectClass='user' AND $objectCategory='Person';