company logo

PropertyHandle :: RepairIndex - Repair Index for current collection

The function checks the physical consistency of the index and repairs detected damages. When no key name is passed, the currently selected index will be repaired. Messages about repair actions are written to the error log file.

The function will remove index entries pointing to invalid instance (deleted). It repairs also index tree information in large indexes.

The function will not detect logical inconsistencies in indexes, i.e. missing index entries or invalid keys. In order to repair this type of inconsistency, one may call repairKey(), rebuildIndex() or repairCollection().

Notes:

Note: after repairing a single index, the number of elements in the index may differ from other indexes. Especially, when entries have been removed from the index, other indexes for the collection should be repaired as well.

The function works similar as callingto calling checkCollection("-C:I -R:u").

Return value:   - internal feature (not documented) ( NString & )

Implementation details

NString PropertyHandle  :: RepairIndex ( NString &key_name_w=NString::Null(), NString &attrstr_w=NString::Null() )

The function returns a string containing repair protocol messages.

  • key_name_w - Key name for conversion Default: NString::Null()
  • attrstr_w - Attribute type

    The attribute type is passed as 0-terminated string. It must be one of the defined values in the enumerated value set for the attribute types defined for the generic attribute.

    Default: NString::Null()