New Ranks & Badges For The Community!
Notice something different? The ranks and associated badges have gone "Star Fleet". See what they all mean HERE
Highlighted
Commodore
Commodore
429 views

How to query an object using an attribute whose datatype is time in edirectory ?

How to query an object using an attribute whose datatype is time in edirectory ? 

Example :

useronboardtime = Aug 17, 2020 5:43:24 PM IST (20200817121324Z) 

Labels (1)
0 Likes
5 Replies
Knowledge Partner Knowledge Partner
Knowledge Partner

The example you posted looks like the LDAP interpretation of a time string. For the IDM engine, you need to use CTIME. You can convert one to the other as needed.

Highlighted
Knowledge Partner Knowledge Partner
Knowledge Partner

In IDM Policy (DirXML Script) you can only query for the exact value, in CTIME as David suggested. I do not think wildcards are supported.

If you use LDAP in ECMA in your driver,, you can query for a lesser than or equal/greater than or equal timestamp to get something within a date range.

0 Likes
Highlighted
Vice Admiral
Vice Admiral

Don't forget that the LDAP time format is not CTIME, it's yyyyMMddHHmmssZ


Highlighted
Commodore
Commodore

The below worked me..

(TerminationDate>=20200803000000Z)

Highlighted
Knowledge Partner Knowledge Partner
Knowledge Partner

That would work as an LDAP search filter, yes.
Maybe you could tell us what you're actually trying to do here, what you've tried, and what happened. Having us guessing probably isn't going to work out.
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.