LDAP Connector
The LDAP connector, known by the type name ldap
, exposes an LDAP directory tree relationally with pushdown support for filtering via criteria. This is typically coupled with the LDAP resource adapter.
Connector Configuration
Metadata
Before issuing queries to LDAP, configure a connection using the SYSADMIN.createConnection()
procedure:
CALL SYSADMIN.createConnection( name => 'ldapalias', jbossCLITemplateName => 'ldap', connectionOrResourceAdapterProperties => 'host=<host>,port=<port>,user-dn="cn\=<cn>,ou\=<ou>,dc\=<dc>",password=<password>,timeout=-1' ) ;;
CALL SYSADMIN.createDatasource( name => 'ldapalias', translator => 'ldap', modelProperties => 'importer.userFullSchemaName=false', translatorProperties => 'SupportsNativeQueries=TRUE' ) ;;
Execution Properties
Property name | Description | Default value |
---|---|---|
| Default base DN for LDAP searches | null |
| Default scope for LDAP searches. Can have one of the following values: |
|
| Restricts searches to |
|
| Uses |
|
| If set to |
|
There are no import settings for the LDAP connector; it also does not provide metadata.
Metadata Directives
String columns with a default value of multivalued-concat
will concatenate all attribute values together in alphabetical order using a ?
delimiter. If a multivalued attribute does not have a default value of multivalued-concat
, then any value may be returned.
Using <ldap_connector>.native Procedure
Here is an example showing the usage of the <ldap_connector>.native procedure:
SELECT x.*
FROM
(
CALL "ldap_src.native"
(
"request" =>
'search;
context-name=OU=dvroles,DC=mydomain,DC=local;
filter=(objectClass=*);
count-limit=100;
timeout=6;
search-scope=ONELEVEL_SCOPE;
attributes=uid,cn'
)
) r
, ARRAYTABLE(r.tuple COLUMNS col1 string, col2 string) x
;;