If you need to delete one or mode indexes from a table, perform the following steps:
// delete the first index
CTTable ATable = new CTTable(ADatabase);
// open the table
ATable.Open("MyTable", OPEN_MODE.NORMAL_OPEN);
// delete the first index - MyIndex0
ATable.DelIndex("MyIndex0");
// alter the table to commit index changes to disk
try
{
ATable.Alter(ALTER_TABLE.NORMAL);
}
catch (CTException err)
{
Console.Write("Alter table failed with error {0}\n", err.GetErrorCode());
}