关于ORM的:
强制使用索引
$query = static::query()->where...
$query->getQuery()->from(DB::raw('`UserEvent` FORCE INDEX (CI_UserEvent_eventType_procStatus)'));
输出原始SQL
DB::connection()->enableQueryLog();
$query = static::query()->where...
print_r(DB::getQueryLog());