[Date Prev][Date Next]
Re: Matching Rules used in Inequality Filters
> attributeType ( 18.104.22.168.4.1.9012.1.1.1.153 NAME 'lastLogin'
> ORDERING caseIgnoreOrderingMatch
> SYNTAX 22.214.171.124.4.1.14126.96.36.199.15)
You should probably have an EQUALITY matching rule too.
Otherwise you can't search for an exact value, compare with a value, add
or remove one value at a time, or use the attribute in a DN. Provided
the server follows the X.500 model properly.
Personally, I always include EQUALITY matching rules unless there is
some specific reason not to.
> /usr/local/openldap-2.1.25/bin/ldapsearch (...)
> "(&(objectclass=*)(lastLogin>=10279010355563))" lastLogin
> but the comparation is by string and it is not what I ment, I need
> numeric comparation
Then you need SYNTAX 188.8.131.52.4.1.14184.108.40.206.27 (Integer),
EQUALITY integerMatch, ORDERING integerOrderingMatch.
Note that Integer does not allow extra zeroes in front of the number.
(Of course, your server might not check that restriction, if so don't
depend on that - a later version of it could become more restrictive.)
> so I changed my attribute to numeric string:
Numeric string is not a number, but a string of digits and spaces.
They are not matched as numbers, but as strings - ignoring spaces.
E.g. "52" matches "5 2", but not "052", and is less than "7".