Page 1 of 1

Integrator OpenLDAPService Retrieve Attributes

Posted: Fri Jun 09, 2017 6:47 am
by jyoung
Is it possible to retrieve other attributes from the OpenLDAPService SEARCH command?

I have a search and its working (partly http://vlforum.lansa.com.au/viewtopic.php?f=3&t=1387) but it only brings back the DN.

I need to get access to other attributes like the UPN, sAMaccountName etc..

Re: Integrator OpenLDAPService Retrieve Attributes

Posted: Wed Jun 14, 2017 1:06 am
by jyoung
The OpenLDAPService has a GET command that can be used to "get" the attributes. http://docs.lansa.com/14/EN/lansa093/in ... 7_2825.htm

Did not see this before, the critical point for me is the requirement of the DN for the entity.

If you don't know the DN, you have to search for it using a filter, then use the DN from the search to get the attributes.

Code: Select all

def_list name(#AttributeList) fields(#STD_TEXTL #STD_STRNG) type(*WORKING) entrys(*MAX)

#JSMXCMD := ('GET DN(&1) ATTRIBUTES(CN, GIVENNAME, DISPLAYNAME) SERVICE_LIST(STD_TEXTL STD_STRNG)').Substitute( #DN )
use builtin(JSMX_COMMAND) with_args(#JSMXHDLE #JSMXCMD) to_get(#JSMXSTS #JSMXMSG #AttributeList)