IObjectField.

Indexed(bool) Method

Summary

turns indexing on or off.
Assembly
Db4objects.Db4o-2010.dll
Namespace
Db4objects.Db4o.Config
Containing Type
IObjectField

Syntax

void Indexed(bool flag)

Remarks

turns indexing on or off.

Field indices dramatically improve query performance but they may considerably reduce storage and update performance.
The best benchmark whether or not an index on a field achieves the desired result is the completed application - with a data load that is typical for it's use.

This configuration setting is only checked when the Db4objects.Db4o.IObjectContainer is opened. If the setting is set to true and an index does not exist, the index will be created. If the setting is set to false and an index does exist the index will be dropped.

In client-server environment this setting should be used on both client and server.

If this setting is applied to an open ObjectContainer it will take an effect on the next time ObjectContainer is opened.

Parameters

Name Type Description
flag bool specify true or false to turn indexing on for this field

Return Value

Type Description
void