[Date Prev][Date Next] [Chronological] [Thread] [Top]

Re: Indexing field causes 0 search results



> I posted one of these earlier messages, and I never got a response. The 
> behavior I see is exactly as you describe. It may have to do with the 

Out of curiosity, in your case, is the attribute you're indexing one that
would use caseIgnoreMatch?

Since I'm indexing a distinguishedName attribute, slapd appears to be using
caseIgnoreIndexer and caseIgnoreFilter to generate the keys to store/retrieve
by.

Unfortunately, at least with caseIgnoreFilter, it seems to be generating a
different key each time it is called with the same value.

I tossed the following into server/slapd/back-ldbm/filterindex.c in
equality_candidates():

        if (strcmp (dbname, "dalMailAliasOwner") == 0) {
           Debug( LDAP_DEBUG_TRACE,
                "   equality_candidates: key[0] = 0x%x\n", keys[0]->bv_val, 0, 0);
           Debug( LDAP_DEBUG_TRACE,
                "   equality_candidates: val[0] = %s\n", ava->aa_value->bv_val, 0, 0);
        }

And what I get is:

Jan 28 12:34:19 Sally slapd[2600]: [ID 608111 local3.debug]    equality_candidates: key[0] = 0xc8be0
Jan 28 12:34:19 Sally slapd[2600]: [ID 873408 local3.debug]    equality_candidates: val[0] = rdn=e189b1e779f8f251a965cf945b36144b,cn=People,dc=Dal,dc=Ca
Jan 28 12:34:20 Sally slapd[2600]: [ID 608111 local3.debug]    equality_candidates: key[0] = 0xc8bc0
Jan 28 12:34:20 Sally slapd[2600]: [ID 873408 local3.debug]    equality_candidates: val[0] = rdn=e189b1e779f8f251a965cf945b36144b,cn=People,dc=Dal,dc=Ca
Jan 28 12:34:21 Sally slapd[2600]: [ID 608111 local3.debug]    equality_candidates: key[0] = 0xc8b00
Jan 28 12:34:21 Sally slapd[2600]: [ID 873408 local3.debug]    equality_candidates: val[0] = rdn=e189b1e779f8f251a965cf945b36144b,cn=People,dc=Dal,dc=Ca
Jan 28 12:34:22 Sally slapd[2600]: [ID 608111 local3.debug]    equality_candidates: key[0] = 0xc8be0
Jan 28 12:34:22 Sally slapd[2600]: [ID 873408 local3.debug]    equality_candidates: val[0] = rdn=e189b1e779f8f251a965cf945b36144b,cn=People,dc=Dal,dc=Ca
Jan 28 12:34:23 Sally slapd[2600]: [ID 608111 local3.debug]    equality_candidates: key[0] = 0xc8bc0
Jan 28 12:34:23 Sally slapd[2600]: [ID 873408 local3.debug]    equality_candidates: val[0] = rdn=e189b1e779f8f251a965cf945b36144b,cn=People,dc=Dal,dc=Ca
Jan 28 12:34:24 Sally slapd[2600]: [ID 608111 local3.debug]    equality_candidates: key[0] = 0xc8b00
Jan 28 12:34:24 Sally slapd[2600]: [ID 873408 local3.debug]    equality_candidates: val[0] = rdn=e189b1e779f8f251a965cf945b36144b,cn=People,dc=Dal,dc=Ca


Am I looking at this the wrong way?