|
Directory Services
_ADDAdds a new entry to an LDAP directory. Syntax_ADD(entryName, entry);
Details
When invoked on an LDAPSERVICES instance, the
The entry parameter is an SCL list that specifies the attributes of the new
directory entry, as well as the values associated with each attribute. The
format of the Item Number Value ----------- ----- 1 Character value representing the attribute name. 2 Numeric or character attribute value. ... n Numeric or character attribute value. Example
The following example adds an entry to an LDAP directory by creating three
attribute/value lists, combining the three lists, and using the combined list
as the dn = "cn=myhost.pc.com,o=Alphalite Airways,c=US"; entry = makelist(); alist1 = makelist(); rc = insertc(alist1, "objectclass", -1); rc = insertc(alist1, "SASDomain", -1); alist2 = makelist(); rc = insertc(alist2, "cn", -1); rc = insertc(alist2, server, -1); alist3 = makelist(); rc = insertc(alist3, "node", -1); rc = insertc(alist3, "oak.unx.com", -1); rc = insertl(entry, alist1, -1); rc = insertl(entry, alist2, -1); rc = insertl(entry, alist3, -1); rc = ds._ADD(dn,entry); rc = dellist(alist1); rc = dellist(alist2); rc = dellist(alist3); |