Skip to content

Commit

Permalink
add max_matches to query
Browse files Browse the repository at this point in the history
  • Loading branch information
thehowl committed Mar 24, 2018
1 parent 3f168df commit 3953624
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion models/set_search.go
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ func SearchSets(db, searchDB *sql.DB, opts SearchOptions) ([]Set, error) {
}

// set limit
setIDsQuery += fmt.Sprintf("ORDER BY WEIGHT() DESC, id DESC LIMIT %d, %d OPTION ranker=sph04", opts.Offset, opts.Amount)
setIDsQuery += fmt.Sprintf("ORDER BY WEIGHT() DESC, id DESC LIMIT %d, %d OPTION ranker=sph04, max_matches=10000000", opts.Offset, opts.Amount)

// fetch rows
rows, err := searchDB.Query(setIDsQuery)
Expand Down

0 comments on commit 3953624

Please sign in to comment.