Cml\Db\MySql\Pdo::forceIndex PHP Method

forceIndex() public method

强制使用索引
public forceIndex ( string $table, string $index, string $tablePrefix = null )
$table string 要强制索引的表名(不带前缀)
$index string 要强制使用的索引
$tablePrefix string 表前缀 不传则获取配置中配置的前缀
    public function forceIndex($table, $index, $tablePrefix = null)
    {
        is_null($tablePrefix) && ($tablePrefix = $this->tablePrefix);
        $this->forceIndex[$tablePrefix . $table] = $index;
        return $this;
    }