Solrで検索クエリーを作るときにどうしてもSQLクエリが先に出てしまうので対応をメモ。 クエリーパラメータでいうとqですね。 検索式 MySQL*1 Solr 一致検索 WHERE title="foo" title:foo 全件 (where無し) *:* AND WHERE title="foo" AND price=200 title:foo AND price:200 OR WHERE title="foo" OR price=200 title:foo OR price:200 NOT WHERE title="foo" AND price<>200 title:foo NOT price:200 範囲指定(未満) WHERE price < 200 price:{* TO 200} 範囲指定(以下) WHERE price <= 200 price:[* TO 200] 範囲