[groonga-dev,01856] Re: HTTP GETで複数カラムへの全文検索

Back to archive index

HAYASHI Kentaro hayas****@clear*****
2013年 10月 2日 (水) 18:23:17 JST


林です。

On Wed, 2 Oct 2013 17:52:14 +0900
HAYASHI Kentaro <hayas****@clear*****> wrote:

snip
> たとえば、curlコマンドで試すとするとこんな感じです。(テーブル名がBooksでワード1がgroonga、ワード2がmroongaと仮定)
> 
> curl "http://localhost:10041/d/select?table=Books&filter=%28title%40\"groonga\"%7C%7Cdescription%40\"groonga\"%29%26%26%28title%40\"mroonga\"%7C%7Cdescription%40\"mroonga\"%29&drilldown=title"
> 
> 上記のようにURLエンコードをしていないと、おっしゃるように二番目の検索ワードが無視されてしまいます。
> うまくいかなかったリクエストでは
> 

curlコマンドを使った例で間違いがあったので訂正します。

誤
curl "http://localhost:10041/d/select?table=Books&filter=%28title%40\"groonga\"%7C%7Cdescription%40\"groonga\"%29%26%26%28title%40\"mroonga\"%7C%7Cdescription%40\"mroonga\"%29&drilldown=title"

正:
curl "http://localhost:10041/d/select?table=Books&filter=%28title%40%22groonga%22%7C%7Cdescription%40%22groonga%22%29%26%26%28title%40%22mroonga%22%7C%7Cdescription%40%22mroonga%22%29&drilldown=title"

「"」もきちんとエンコードしないといけませんでした。。。

-- 
HAYASHI Kentaro <hayas****@clear*****>




groonga-dev メーリングリストの案内
Back to archive index