esqueleto-textsearch-1.1.0: PostgreSQL full text search for Esqueleto
Safe HaskellSafe-Inferred
LanguageHaskell2010

Database.Esqueleto.TextSearch.Language

Synopsis

Documentation

prefixAndQuery :: SearchTerm -> SqlExpr (Value (TsQuery Lexemes)) Source #

format the query into lexemes the result can be used in @@. for example:

     where_ $ (index ^. UnitSearchIndexDocument) @@. prefixAndQuery query
  

toSearchTerm :: Text -> Maybe SearchTerm Source #

constructs a valid search query, removes a bunch of illegal characters and splits the terms for better results

data SearchTerm Source #

A valid search term

Instances

Instances details
Show SearchTerm Source # 
Instance details

Defined in Database.Esqueleto.TextSearch.Language