| LDAP CALL Routine Interface |
| Syntax | |
| Arguments | |
| Details | |
| Examples |
Syntax |
| CALL LDAPS_MODIFY(lHandle, entryName, rc, modifyType1, attr1, numValues1 <, attr1Val1, ...attr1ValN> <..., modifyTypeN, attrN, numValuesN<, attrNVal1..., attrNValN>>); |
| 1Handle |
specifies the connection handle that is returned by the LDAPS_OPEN CALL routine. The connection handle identifies the open connection to use when modifying the LDAP directory entry.
| ||||
| entryname |
names the directory entry to be modified.
| ||||
| rc |
receives a return code that indicates success or failure.
| ||||
| modifyType |
specifies the type of modification. Valid values are ADD, DELETE, and REPLACE.
| ||||
| attr |
identifies the attribute to be modified.
| ||||
| numValues |
specifies the number of values to be modified for the specified attribute.
| ||||
| attrVal1, ...attrValN |
specifies zero or more attribute values, the number of which is specified by the numValues parameter.
|
| Details |
Zero or more attributes can be specified.
If the value of the modifyType parameter is DELETE and if the value of the numValues parameter is 0, then the entire attribute and all of its values are deleted.
If the value of the modifyType parameter is DELETE and if the value of the numValues parameter is 1 or greater, then only the specified values will be deleted.
If the value of the modifyType parameter is REPLACE, then the existing attribute and all of its values are deleted and replaced with the specified attribute and its newly specified values.
| Examples |
The following example modifies the node associated with a distinguished name.
dn = "cn=alpair02.unx.com,o=Alphalite Airways,c=US"; attrName = "objectclass"; objValue = "SASDomain"; attrName2 = "node"; nodeValue = "oak.unx.com"; CALL LDAPS_MODIFY(lHandle, dn, rc, "ADD", attrName, 1, objValue, "DELETE", attrName2, 0);
The following example modifies a filter associated with an LDAP entry.
dn="sasSubscriberCn=JohnSmith,cn=sassubscribers, sasComponent=sasPublishSubscribe,cn=SAS,o=Alphalite Airways,c=US"; attrName = "sasDescription"; attrName2 = "sasEntryInclusionFilter"; val = "gif"; val2 = "dataset"; htmlvalue = "html"; CALL LDAPS_MODIFY(lHandle, dn, rc, "DELETE", attrName, 0, "REPLACE", attrName2, 3, val, val2, htmlvalue);
Copyright © 2008 by SAS Institute Inc., Cary, NC, USA. All rights reserved.