2013-05-28 56 views
1

我試圖執行索引和搜索微軟辦公室的所有產品。我發現它不適用於Excel二進制書(.xlsb)。彈性搜索工作excel二進制工作簿

我已成功執行索引,但無法從中找到單詞。

我曾嘗試以下步驟:

  curl -X PUT "localhost:9200/test/attachment/_mapping" -d '{ 
      "attachment" : { 
      "properties" : { 
       "file" : { 
       "type" : "attachment", 
       "fields" : { 
        "title" : { "store" : "yes" }, 
        "file" : { "term_vector":"with_positions_offsets", "store":"yes" } 
       } 
       } 
      } 
      } 
     }' 

     coded=`cat test.xlsb | perl -MMIME::Base64 -ne 'print encode_base64($_)'` 
     json="{\"file\":\"${coded}\"}" 
     echo "$json" > json.file 
     curl -X POST "localhost:9200/test/attachment/" -d @json.file 

     curl "localhost:9200/_search?pretty=true" -d '{ 
      "fields" : ["title"], 
      "query" : { 
      "query_string" : { 
       "query" : "sheet" 
      } 
      }, 
      "highlight" : { 
      "fields" : { 
       "file" : {} 
      } 
      } 
      }' 
+0

你能描述一下你到目前爲止做過的事嗎(捲曲娛樂)? – dadoonet

+0

第一次分配shrad第二次創建映射第三次轉換成base64第四次索引文件curl -X POST「localhost:9200/test/attachment /」@ jxlsb.file「然後試圖在其中搜索但無法得到正確的結果 – Lav

+0

你能請更新您的問題並給出您發送的查詢? – dadoonet

回答

0

我們剛纔添加的流/只讀在POI XLSB支持(3.15-beta3版推出)。一旦發佈,我們將升級Apache Tika(1.15?),然後一旦彈性升級,您應該很好。

僅僅4年後!

+0

Apache Tika 1.15最近發佈,現在它可以處理XLSB。 –