Spelling auto-correction for dimension search and record search automatically computes alternate spellings for user query terms that are misspelled.

The Did You Mean (DYM) feature provides the user with explicit alternative suggestions for a keyword search. Both features are fully explained in the "Implementing Spelling Correction and Did You Mean" section.

Both DYM and spelling auto-correction work normally when the Ntt parameter is used with Nrs. For example, in the following query:

Nrs=collection()/record[Recordtype = "book"]
	&Ntk=description&Ntt=storye&Ntx=mode+matchall

the misspelled term storye is auto-corrected to story (assuming that the MDEX Engine was started with the --spl flag).

If DYM is enabled instead of auto-correction (using the --dym flag), then the Nty=1 parameter can be used in the query:

Nrs=collection()/record[Recordtype = "book"]
	&Ntk=description&Ntt=storye&Ntx=mode+matchall&Nty=1

In this case, no records are returned (assuming that the misspelled term storye is not in the data set), but the term story is returned as a DYM suggestion.

If both spelling auto-correction and DYM are enabled, the spelling auto-correction feature will take precedence. However, for a full text search with the endeca:matches() function, the spelling auto-correction feature will work, but the DYM feature is not supported. For example, in this query:

collection()/record
[
	endeca:matches(.,"description","storye")
]

the misspelled term storye is auto-corrected to story if auto-correction is enabled. If DYM is enabled but auto-correction is not, then no records are returned (again assuming that the misspelled term storye is not in the data set).


Copyright © Legal Notices