def index
@search = LogFile.search(params[:q])
@log_files = @search.result(distinct: false).includes(:search_statistic).page(params[:page]).per(5)
end
def index
@search = LogFile.search(params[:q])
@log_files = @search.result(distinct: true).includes(:search_statistic).page(params[:page]).per(5)
end
PG::InvalidColumnReference: ERROR: for SELECT DISTINCT, ORDER BY expressions must appear in select list