class JsonApiServer::SqlLike

Query LIKE builder, .i.e., where('title LIKE ?', '%foo%'). Wildcards are added based on configs. Defaults to '%<value>%'

Public Instance Methods

to_query(model) click to toggle source
# File lib/json_api_server/filter_builders.rb, line 89
def to_query(model)
  val = add_wildcards(value)
  model.where("#{full_column_name(model)} LIKE ?", val)
end