Indexes Indexes can be defined directly in the main or custom vardefs.php for module, in an array under the key 'indices'. Below is the example of defining several indices: 'indices' => array ( array( 'name' => 'idx_modulename_name', 'type' => 'index', 'fields' => array('name'), ), array( 'name' => 'idx_modulename_assigned_deleted', 'type' => 'index', 'fields' => array('assigned_user_id', 'deleted'), ), ), The name of the index should start with idx_ and be unique across the database. The possible values for ‘type’ include 'primary' for a primary key or 'index' for a normal index. The fields list matches the column names used in the database.
Copyright 2004-2008 SugarCRM Inc. Product License