rroonga 2.0.8-x86-mingw32 → 2.1.0-x86-mingw32
Sign up to get free protection for your applications and to get access to all the features.
- data/README.textile +2 -2
- data/bin/groonga-index-dump +47 -0
- data/doc/text/news.textile +733 -0
- data/doc/text/tutorial.textile +535 -0
- data/example/bookmark.rb +1 -1
- data/ext/groonga/rb-grn-database.c +21 -24
- data/ext/groonga/rb-grn-double-array-trie.c +50 -58
- data/ext/groonga/rb-grn-exception.c +18 -1
- data/ext/groonga/rb-grn-hash.c +18 -3
- data/ext/groonga/rb-grn-index-column.c +50 -2
- data/ext/groonga/rb-grn-normalizer.c +83 -0
- data/ext/groonga/rb-grn-object.c +18 -14
- data/ext/groonga/rb-grn-patricia-trie.c +17 -2
- data/ext/groonga/rb-grn-query-logger.c +263 -0
- data/ext/groonga/rb-grn-snippet.c +6 -0
- data/ext/groonga/rb-grn-table-key-support.c +204 -13
- data/ext/groonga/rb-grn-table.c +124 -46
- data/ext/groonga/rb-grn.h +14 -3
- data/ext/groonga/rb-groonga.c +2 -0
- data/lib/1.8/groonga.so +0 -0
- data/lib/1.9/groonga.so +0 -0
- data/lib/groonga.rb +2 -1
- data/lib/groonga/database.rb +7 -0
- data/lib/groonga/dumper.rb +21 -2
- data/lib/groonga/index-column.rb +170 -0
- data/lib/groonga/query-logger.rb +129 -0
- data/lib/groonga/record.rb +32 -8
- data/lib/groonga/schema.rb +231 -288
- data/rroonga-build.rb +2 -2
- data/rroonga.gemspec +11 -7
- data/test/groonga-test-utils.rb +18 -6
- data/test/test-hash.rb +49 -20
- data/test/test-index-cursor.rb +4 -4
- data/{Gemfile → test/test-normalizer.rb} +9 -5
- data/test/test-pagination.rb +1 -1
- data/test/test-patricia-trie.rb +8 -0
- data/test/test-schema.rb +16 -13
- data/test/test-snippet.rb +5 -0
- data/test/test-table.rb +24 -12
- data/test/test-view.rb +0 -1
- data/vendor/local/bin/groonga-benchmark.exe +0 -0
- data/vendor/local/bin/groonga.exe +0 -0
- data/vendor/local/bin/libgroonga-0.dll +0 -0
- data/vendor/local/bin/libmecab-1.dll +0 -0
- data/vendor/local/bin/libmsgpack-3.dll +0 -0
- data/vendor/local/bin/libmsgpackc-2.dll +0 -0
- data/vendor/local/bin/mecab-config +2 -2
- data/vendor/local/bin/mecab.exe +0 -0
- data/vendor/local/etc/groonga/httpd/groonga-httpd.conf +2 -2
- data/vendor/local/include/groonga/groonga.h +25 -14
- data/vendor/local/include/groonga/groonga/normalizer.h +55 -0
- data/vendor/local/include/groonga/groonga/tokenizer.h +33 -13
- data/vendor/local/lib/groonga/plugins/query_expanders/tsv.a +0 -0
- data/vendor/local/lib/groonga/plugins/query_expanders/tsv.dll +0 -0
- data/vendor/local/lib/groonga/plugins/query_expanders/tsv.dll.a +0 -0
- data/vendor/local/lib/groonga/plugins/query_expanders/tsv.la +2 -2
- data/vendor/local/lib/groonga/plugins/suggest/suggest.a +0 -0
- data/vendor/local/lib/groonga/plugins/suggest/suggest.dll +0 -0
- data/vendor/local/lib/groonga/plugins/suggest/suggest.dll.a +0 -0
- data/vendor/local/lib/groonga/plugins/suggest/suggest.la +2 -2
- data/vendor/local/lib/groonga/plugins/table/table.a +0 -0
- data/vendor/local/lib/groonga/plugins/table/table.dll +0 -0
- data/vendor/local/lib/groonga/plugins/table/table.dll.a +0 -0
- data/vendor/local/lib/groonga/plugins/table/table.la +2 -2
- data/vendor/local/lib/groonga/plugins/tokenizers/mecab.a +0 -0
- data/vendor/local/lib/groonga/plugins/tokenizers/mecab.dll +0 -0
- data/vendor/local/lib/groonga/plugins/tokenizers/mecab.dll.a +0 -0
- data/vendor/local/lib/groonga/plugins/tokenizers/mecab.la +2 -2
- data/vendor/local/lib/libgroonga.a +0 -0
- data/vendor/local/lib/libgroonga.dll.a +0 -0
- data/vendor/local/lib/libgroonga.la +2 -2
- data/vendor/local/lib/libmecab.a +0 -0
- data/vendor/local/lib/libmecab.dll.a +0 -0
- data/vendor/local/lib/libmecab.la +1 -1
- data/vendor/local/lib/libmsgpack.a +0 -0
- data/vendor/local/lib/libmsgpack.dll.a +0 -0
- data/vendor/local/lib/libmsgpack.la +1 -1
- data/vendor/local/lib/libmsgpackc.a +0 -0
- data/vendor/local/lib/libmsgpackc.dll.a +0 -0
- data/vendor/local/lib/libmsgpackc.la +1 -1
- data/vendor/local/lib/pkgconfig/groonga.pc +3 -3
- data/vendor/local/libexec/mecab/mecab-cost-train.exe +0 -0
- data/vendor/local/libexec/mecab/mecab-dict-gen.exe +0 -0
- data/vendor/local/libexec/mecab/mecab-dict-index.exe +0 -0
- data/vendor/local/libexec/mecab/mecab-system-eval.exe +0 -0
- data/vendor/local/libexec/mecab/mecab-test-gen.exe +0 -0
- data/vendor/local/sbin/groonga-httpd-restart +9 -3
- data/vendor/local/share/doc/groonga/en/html/.buildinfo +1 -1
- data/vendor/local/share/doc/groonga/en/html/_sources/install/centos.txt +6 -6
- data/vendor/local/share/doc/groonga/en/html/_sources/install/debian.txt +3 -3
- data/vendor/local/share/doc/groonga/en/html/_sources/install/fedora.txt +4 -4
- data/vendor/local/share/doc/groonga/en/html/_sources/install/mac_os_x.txt +3 -3
- data/vendor/local/share/doc/groonga/en/html/_sources/install/others.txt +3 -3
- data/vendor/local/share/doc/groonga/en/html/_sources/install/solaris.txt +3 -3
- data/vendor/local/share/doc/groonga/en/html/_sources/install/ubuntu.txt +3 -42
- data/vendor/local/share/doc/groonga/en/html/_sources/install/windows.txt +16 -16
- data/vendor/local/share/doc/groonga/en/html/_sources/news.txt +59 -0
- data/vendor/local/share/doc/groonga/en/html/_sources/tutorial/match_columns.txt +129 -0
- data/vendor/local/share/doc/groonga/en/html/_static/doctools.js +0 -12
- data/vendor/local/share/doc/groonga/en/html/_static/searchtools.js +3 -3
- data/vendor/local/share/doc/groonga/en/html/characteristic.html +6 -6
- data/vendor/local/share/doc/groonga/en/html/community.html +6 -6
- data/vendor/local/share/doc/groonga/en/html/contribution.html +6 -6
- data/vendor/local/share/doc/groonga/en/html/contribution/development.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/development/com.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/development/document.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/development/query.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/development/release.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/development/test.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/documentation.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/documentation/c-api.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/documentation/i18n.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/contribution/report.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/development.html +6 -6
- data/vendor/local/share/doc/groonga/en/html/development/travis-ci.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/genindex.html +6 -6
- data/vendor/local/share/doc/groonga/en/html/geolocation_search.html +6 -6
- data/vendor/local/share/doc/groonga/en/html/index.html +12 -12
- data/vendor/local/share/doc/groonga/en/html/install.html +10 -11
- data/vendor/local/share/doc/groonga/en/html/install/centos.html +11 -11
- data/vendor/local/share/doc/groonga/en/html/install/debian.html +8 -8
- data/vendor/local/share/doc/groonga/en/html/install/fedora.html +9 -9
- data/vendor/local/share/doc/groonga/en/html/install/mac_os_x.html +8 -8
- data/vendor/local/share/doc/groonga/en/html/install/others.html +8 -8
- data/vendor/local/share/doc/groonga/en/html/install/solaris.html +8 -8
- data/vendor/local/share/doc/groonga/en/html/install/ubuntu.html +16 -53
- data/vendor/local/share/doc/groonga/en/html/install/windows.html +16 -16
- data/vendor/local/share/doc/groonga/en/html/limitations.html +6 -6
- data/vendor/local/share/doc/groonga/en/html/news.html +146 -82
- data/vendor/local/share/doc/groonga/en/html/news/0.x.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/news/1.0.x.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/news/1.1.x.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/news/1.2.x.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/news/senna.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/objects.inv +0 -0
- data/vendor/local/share/doc/groonga/en/html/reference.html +6 -6
- data/vendor/local/share/doc/groonga/en/html/reference/api.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/api/grn_expr.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/cast.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/command.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/command/command_version.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/command/output_format.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/command/return_code.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/cache_limit.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/check.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/clearlock.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/column_create.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/column_list.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/column_remove.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/define_selector.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/defrag.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/delete.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/dump.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/load.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/log_level.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/log_put.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/log_reopen.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/quit.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/register.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/select.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/shutdown.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/status.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/suggest.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/table_create.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/table_list.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/table_remove.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands/view_add.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands_not_implemented/add.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands_not_implemented/get.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/commands_not_implemented/set.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/executables.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/executables/grnslap.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/executables/grntest.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga-httpd.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga-server-http.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga-suggest-create-dataset.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/function.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/functions/edit_distance.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/functions/geo_distance.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/functions/geo_in_circle.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/functions/geo_in_rectangle.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/functions/now.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/functions/rand.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/functions/snippet_html.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/grn_expr.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/grn_expr/query_syntax.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/grn_expr/script_syntax.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/indexing.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/log.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/output.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/pseudo_column.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/query_expanders.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/query_expanders/tsv.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/tokenizers.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/reference/type.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/search.html +6 -6
- data/vendor/local/share/doc/groonga/en/html/searchindex.js +1 -1
- data/vendor/local/share/doc/groonga/en/html/server.html +6 -6
- data/vendor/local/share/doc/groonga/en/html/server/gqtp.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/server/http.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/server/http/comparison.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/server/http/groonga-httpd.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/server/http/groonga.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/spec.html +6 -6
- data/vendor/local/share/doc/groonga/en/html/spec/gqtp.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/spec/search.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/suggest.html +6 -6
- data/vendor/local/share/doc/groonga/en/html/suggest/completion.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/suggest/correction.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/suggest/introduction.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/suggest/suggestion.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/suggest/tutorial.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/troubleshooting.html +6 -6
- data/vendor/local/share/doc/groonga/en/html/troubleshooting/different_results_with_the_same_keyword.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial.html +8 -7
- data/vendor/local/share/doc/groonga/en/html/tutorial/data.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/drilldown.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/index.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/introduction.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/lexicon.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/match_columns.html +265 -7
- data/vendor/local/share/doc/groonga/en/html/tutorial/micro_blog.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/network.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/patricia_trie.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/query_expansion.html +5 -5
- data/vendor/local/share/doc/groonga/en/html/tutorial/search.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/.buildinfo +1 -1
- data/vendor/local/share/doc/groonga/ja/html/_sources/install/centos.txt +6 -6
- data/vendor/local/share/doc/groonga/ja/html/_sources/install/debian.txt +3 -3
- data/vendor/local/share/doc/groonga/ja/html/_sources/install/fedora.txt +4 -4
- data/vendor/local/share/doc/groonga/ja/html/_sources/install/mac_os_x.txt +3 -3
- data/vendor/local/share/doc/groonga/ja/html/_sources/install/others.txt +3 -3
- data/vendor/local/share/doc/groonga/ja/html/_sources/install/solaris.txt +3 -3
- data/vendor/local/share/doc/groonga/ja/html/_sources/install/ubuntu.txt +3 -42
- data/vendor/local/share/doc/groonga/ja/html/_sources/install/windows.txt +16 -16
- data/vendor/local/share/doc/groonga/ja/html/_sources/news.txt +59 -0
- data/vendor/local/share/doc/groonga/ja/html/_sources/tutorial/match_columns.txt +129 -0
- data/vendor/local/share/doc/groonga/ja/html/_static/doctools.js +0 -12
- data/vendor/local/share/doc/groonga/ja/html/_static/searchtools.js +2 -2
- data/vendor/local/share/doc/groonga/ja/html/characteristic.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/community.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/contribution.html +9 -9
- data/vendor/local/share/doc/groonga/ja/html/contribution/development.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/development/com.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/development/document.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/development/query.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/development/release.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/development/test.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/contribution/documentation.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/contribution/documentation/c-api.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/contribution/documentation/i18n.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/contribution/report.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/development.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/development/travis-ci.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/genindex.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/geolocation_search.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/index.html +12 -12
- data/vendor/local/share/doc/groonga/ja/html/install.html +10 -11
- data/vendor/local/share/doc/groonga/ja/html/install/centos.html +11 -11
- data/vendor/local/share/doc/groonga/ja/html/install/debian.html +8 -8
- data/vendor/local/share/doc/groonga/ja/html/install/fedora.html +9 -9
- data/vendor/local/share/doc/groonga/ja/html/install/mac_os_x.html +8 -8
- data/vendor/local/share/doc/groonga/ja/html/install/others.html +8 -8
- data/vendor/local/share/doc/groonga/ja/html/install/solaris.html +8 -8
- data/vendor/local/share/doc/groonga/ja/html/install/ubuntu.html +16 -51
- data/vendor/local/share/doc/groonga/ja/html/install/windows.html +16 -16
- data/vendor/local/share/doc/groonga/ja/html/limitations.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/news.html +126 -82
- data/vendor/local/share/doc/groonga/ja/html/news/0.x.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/news/1.0.x.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/news/1.1.x.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/news/1.2.x.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/news/senna.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/objects.inv +0 -0
- data/vendor/local/share/doc/groonga/ja/html/reference.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/reference/api.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_expr.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/cast.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/command.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/command/command_version.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/command/output_format.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/command/return_code.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/cache_limit.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/check.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/clearlock.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/column_create.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/column_list.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/column_remove.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/define_selector.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/defrag.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/delete.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/dump.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/load.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/log_level.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/log_put.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/log_reopen.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/quit.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/register.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/select.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/shutdown.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/status.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/suggest.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/table_create.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/table_list.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/table_remove.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands/view_add.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands_not_implemented/add.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands_not_implemented/get.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/commands_not_implemented/set.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/executables.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/executables/grnslap.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/executables/grntest.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga-httpd.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga-server-http.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga-suggest-create-dataset.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/function.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/edit_distance.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/geo_distance.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/geo_in_circle.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/geo_in_rectangle.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/now.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/rand.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/functions/snippet_html.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/grn_expr.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/grn_expr/query_syntax.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/grn_expr/script_syntax.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/indexing.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/log.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/output.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/pseudo_column.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/query_expanders.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/query_expanders/tsv.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/tokenizers.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/reference/type.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/search.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/searchindex.js +1 -1
- data/vendor/local/share/doc/groonga/ja/html/server.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/server/gqtp.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/server/http.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/server/http/comparison.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/server/http/groonga-httpd.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/server/http/groonga.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/spec.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/spec/gqtp.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/spec/search.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/suggest.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/suggest/completion.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/suggest/correction.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/suggest/introduction.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/suggest/suggestion.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/suggest/tutorial.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/troubleshooting.html +6 -6
- data/vendor/local/share/doc/groonga/ja/html/troubleshooting/different_results_with_the_same_keyword.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial.html +8 -7
- data/vendor/local/share/doc/groonga/ja/html/tutorial/data.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/drilldown.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/index.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/introduction.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/lexicon.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/match_columns.html +259 -7
- data/vendor/local/share/doc/groonga/ja/html/tutorial/micro_blog.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/network.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/patricia_trie.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/query_expansion.html +5 -5
- data/vendor/local/share/doc/groonga/ja/html/tutorial/search.html +5 -5
- data/vendor/local/share/doc/groonga/source/example/tutorial/match_columns-nested-index-data-with-three-relationship.log +23 -0
- data/vendor/local/share/doc/groonga/source/example/tutorial/match_columns-nested-index-data.log +16 -0
- data/vendor/local/share/doc/groonga/source/example/tutorial/match_columns-nested-index-schema-with-three-relationship.log +30 -0
- data/vendor/local/share/doc/groonga/source/example/tutorial/match_columns-nested-index-schema.log +20 -0
- data/vendor/local/share/doc/groonga/source/example/tutorial/match_columns-nested-index-select-with-three-relationship.log +86 -0
- data/vendor/local/share/doc/groonga/source/example/tutorial/match_columns-nested-index-select.log +41 -0
- data/vendor/local/share/doc/groonga/source/install/centos.txt +6 -6
- data/vendor/local/share/doc/groonga/source/install/debian.txt +3 -3
- data/vendor/local/share/doc/groonga/source/install/fedora.txt +4 -4
- data/vendor/local/share/doc/groonga/source/install/mac_os_x.txt +3 -3
- data/vendor/local/share/doc/groonga/source/install/others.txt +3 -3
- data/vendor/local/share/doc/groonga/source/install/solaris.txt +3 -3
- data/vendor/local/share/doc/groonga/source/install/ubuntu.txt +3 -42
- data/vendor/local/share/doc/groonga/source/install/windows.txt +16 -16
- data/vendor/local/share/doc/groonga/source/news.txt +59 -0
- data/vendor/local/share/doc/groonga/source/tutorial/match_columns.txt +129 -0
- data/vendor/local/share/man/ja/man1/groonga.1 +338 -93
- data/vendor/local/share/man/man1/groonga.1 +341 -92
- metadata +1258 -1242
- data/AUTHORS +0 -5
- data/Rakefile +0 -203
- data/bin/groonga-query-log-extract +0 -117
@@ -119,9 +119,9 @@ Install required packages to build groonga::
|
|
119
119
|
|
120
120
|
Download source::
|
121
121
|
|
122
|
-
% wget http://packages.groonga.org/source/groonga/groonga-2.0.
|
123
|
-
% tar xvzf groonga-2.0.
|
124
|
-
% cd groonga-2.0
|
122
|
+
% wget http://packages.groonga.org/source/groonga/groonga-2.1.0.tar.gz
|
123
|
+
% tar xvzf groonga-2.1.0.tar.gz
|
124
|
+
% cd groonga-2.1.0
|
125
125
|
|
126
126
|
Configure (see :ref:`source-configure` about ``configure`` options)::
|
127
127
|
|
@@ -27,7 +27,7 @@ Fedora 17
|
|
27
27
|
|
28
28
|
Install::
|
29
29
|
|
30
|
-
% sudo rpm -ivh http://packages.groonga.org/fedora/groonga-release-1.1.0-
|
30
|
+
% sudo rpm -ivh http://packages.groonga.org/fedora/groonga-release-1.1.0-1.noarch.rpm
|
31
31
|
% sudo yum update
|
32
32
|
% sudo yum install -y groonga
|
33
33
|
|
@@ -65,9 +65,9 @@ Install required packages to build groonga::
|
|
65
65
|
|
66
66
|
Download source::
|
67
67
|
|
68
|
-
% wget http://packages.groonga.org/source/groonga/groonga-2.0.
|
69
|
-
% tar xvzf groonga-2.0.
|
70
|
-
% cd groonga-2.0
|
68
|
+
% wget http://packages.groonga.org/source/groonga/groonga-2.1.0.tar.gz
|
69
|
+
% tar xvzf groonga-2.1.0.tar.gz
|
70
|
+
% cd groonga-2.1.0
|
71
71
|
|
72
72
|
Configure (see :ref:`source-configure` about ``configure`` options)::
|
73
73
|
|
@@ -36,9 +36,9 @@ Install `Xcode <https://developer.apple.com/xcode/>`_.
|
|
36
36
|
|
37
37
|
Download source::
|
38
38
|
|
39
|
-
% curl -O http://packages.groonga.org/source/groonga/groonga-2.0.
|
40
|
-
% tar xvzf groonga-2.0.
|
41
|
-
% cd groonga-2.0
|
39
|
+
% curl -O http://packages.groonga.org/source/groonga/groonga-2.1.0.tar.gz
|
40
|
+
% tar xvzf groonga-2.1.0.tar.gz
|
41
|
+
% cd groonga-2.1.0
|
42
42
|
|
43
43
|
Configure (see :ref:`source-configure` about ``configure`` options)::
|
44
44
|
|
@@ -74,9 +74,9 @@ Build from source
|
|
74
74
|
Groonga uses GNU build system. So the following is the simplest build
|
75
75
|
steps::
|
76
76
|
|
77
|
-
% wget http://packages.groonga.org/source/groonga/groonga-2.0.
|
78
|
-
% tar xvzf groonga-2.0.
|
79
|
-
% cd groonga-2.0
|
77
|
+
% wget http://packages.groonga.org/source/groonga/groonga-2.1.0.tar.gz
|
78
|
+
% tar xvzf groonga-2.1.0.tar.gz
|
79
|
+
% cd groonga-2.1.0
|
80
80
|
% ./configure
|
81
81
|
% make
|
82
82
|
% sudo make install
|
@@ -17,9 +17,9 @@ Install required packages to build groonga::
|
|
17
17
|
|
18
18
|
Download source::
|
19
19
|
|
20
|
-
% wget http://packages.groonga.org/source/groonga/groonga-2.0.
|
21
|
-
% gtar xvzf groonga-2.0.
|
22
|
-
% cd groonga-2.0
|
20
|
+
% wget http://packages.groonga.org/source/groonga/groonga-2.1.0.tar.gz
|
21
|
+
% gtar xvzf groonga-2.1.0.tar.gz
|
22
|
+
% cd groonga-2.1.0
|
23
23
|
|
24
24
|
Configure with ``CFLAGS="-m64" CXXFLAGS="-m64"`` variables. They are
|
25
25
|
needed for building 64-bit version. To build 32-bit version, just
|
@@ -49,45 +49,6 @@ There is a package that provides `Munin
|
|
49
49
|
<http://munin-monitoring.org/>`_ plugins. If you want to monitor
|
50
50
|
groonga status by Munin, install groonga-munin-plugins package.
|
51
51
|
|
52
|
-
Install groonga-munin-plugins package::
|
53
|
-
|
54
|
-
% sudo apt-get -y install groonga-munin-plugins
|
55
|
-
|
56
|
-
11.04 Natty Narwhal
|
57
|
-
-------------------
|
58
|
-
|
59
|
-
.. note::
|
60
|
-
|
61
|
-
Enable the universe repository to install groonga::
|
62
|
-
|
63
|
-
% sudo cp /etc/apt/sources.list /etc/apt/sources.list.d/universe.list
|
64
|
-
% sudo sed -i'' -e 's/main/universe/' /etc/apt/sources.list.d/universe.list
|
65
|
-
|
66
|
-
Add the groonga apt repository.
|
67
|
-
|
68
|
-
/etc/apt/sources.list.d/groonga.list::
|
69
|
-
|
70
|
-
deb http://packages.groonga.org/ubuntu/ natty universe
|
71
|
-
deb-src http://packages.groonga.org/ubuntu/ natty universe
|
72
|
-
|
73
|
-
Install::
|
74
|
-
|
75
|
-
% sudo apt-get update
|
76
|
-
% sudo apt-get -y --allow-unauthenticated install groonga-keyring
|
77
|
-
% sudo apt-get update
|
78
|
-
% sudo apt-get -y install groonga
|
79
|
-
|
80
|
-
If you want to use `MeCab <http://mecab.sourceforge.net/>`_ as a
|
81
|
-
tokenizer, install groonga-tokenizer-mecab package.
|
82
|
-
|
83
|
-
Install groonga-tokenizer-mecab package::
|
84
|
-
|
85
|
-
% sudo apt-get -y install groonga-tokenizer-mecab
|
86
|
-
|
87
|
-
There is a package that provides `Munin
|
88
|
-
<http://munin-monitoring.org/>`_ plugins. If you want to monitor
|
89
|
-
groonga status by Munin, install groonga-munin-plugins package.
|
90
|
-
|
91
52
|
Install groonga-munin-plugins package::
|
92
53
|
|
93
54
|
% sudo apt-get -y install groonga-munin-plugins
|
@@ -218,9 +179,9 @@ Install required packages to build groonga::
|
|
218
179
|
|
219
180
|
Download source::
|
220
181
|
|
221
|
-
% wget http://packages.groonga.org/source/groonga/groonga-2.0.
|
222
|
-
% tar xvzf groonga-2.0.
|
223
|
-
% cd groonga-2.0
|
182
|
+
% wget http://packages.groonga.org/source/groonga/groonga-2.1.0.tar.gz
|
183
|
+
% tar xvzf groonga-2.1.0.tar.gz
|
184
|
+
% cd groonga-2.1.0
|
224
185
|
|
225
186
|
Configure (see :ref:`source-configure` about ``configure`` options)::
|
226
187
|
|
@@ -17,12 +17,12 @@ size data.
|
|
17
17
|
Installer
|
18
18
|
---------
|
19
19
|
|
20
|
-
For 32-bit environment, download `groonga-2.0
|
21
|
-
<http://packages.groonga.org/windows/groonga/groonga-2.0
|
20
|
+
For 32-bit environment, download `groonga-2.1.0-x86.exe
|
21
|
+
<http://packages.groonga.org/windows/groonga/groonga-2.1.0-x86.exe>`_
|
22
22
|
and run it.
|
23
23
|
|
24
|
-
For 64-bit environment, download `groonga-2.0
|
25
|
-
<http://packages.groonga.org/windows/groonga/groonga-2.0
|
24
|
+
For 64-bit environment, download `groonga-2.1.0-x64.exe
|
25
|
+
<http://packages.groonga.org/windows/groonga/groonga-2.1.0-x64.exe>`_
|
26
26
|
and run it.
|
27
27
|
|
28
28
|
Use command prompt for :doc:`/reference/executables/groonga` installed in start menu.
|
@@ -30,12 +30,12 @@ Use command prompt for :doc:`/reference/executables/groonga` installed in start
|
|
30
30
|
zip
|
31
31
|
---
|
32
32
|
|
33
|
-
For 32-bit environment, download `groonga-2.0
|
34
|
-
<http://packages.groonga.org/windows/groonga/groonga-2.0
|
33
|
+
For 32-bit environment, download `groonga-2.1.0-x86.zip
|
34
|
+
<http://packages.groonga.org/windows/groonga/groonga-2.1.0-x86.zip>`_
|
35
35
|
and extract it.
|
36
36
|
|
37
|
-
For 64-bit environment, download `groonga-2.0
|
38
|
-
<http://packages.groonga.org/windows/groonga/groonga-2.0
|
37
|
+
For 64-bit environment, download `groonga-2.1.0-x64.zip
|
38
|
+
<http://packages.groonga.org/windows/groonga/groonga-2.1.0-x64.zip>`_
|
39
39
|
and extract it.
|
40
40
|
|
41
41
|
:doc:`/reference/executables/groonga` is in ``bin`` folder.
|
@@ -50,38 +50,38 @@ Windows. Here are required tools:
|
|
50
50
|
<http://www.microsoft.com/japan/msdn/vstudio/express/>`_
|
51
51
|
* `CMake <http://www.cmake.org/>`_
|
52
52
|
|
53
|
-
Download zipped source `groonga-2.0.
|
54
|
-
<http://packages.groonga.org/source/groonga/groonga-2.0.
|
53
|
+
Download zipped source `groonga-2.1.0.zip
|
54
|
+
<http://packages.groonga.org/source/groonga/groonga-2.1.0.zip>`_
|
55
55
|
and extract it.
|
56
56
|
|
57
57
|
Start ``Visual Studio Command Prompt (2010)`` installed by Microsoft
|
58
58
|
Visual Studio 2010 Express and move to the groonga's source folder::
|
59
59
|
|
60
|
-
> cd c:\Users\%USERNAME%\Downloads\groonga-2.0
|
60
|
+
> cd c:\Users\%USERNAME%\Downloads\groonga-2.1.0
|
61
61
|
|
62
62
|
Configure by ``cmake``. The following commnad line is for 64-bit
|
63
63
|
version. To build 32-bit version, use ``-G "Visual Studio 10"``
|
64
64
|
parameter instead::
|
65
65
|
|
66
|
-
groonga-2.0
|
66
|
+
groonga-2.1.0> cmake . -G "Visual Studio 10 Win64" -DCMAKE_INSTALL_PREFIX=C:\groonga
|
67
67
|
|
68
68
|
Build by Visual C++ 2010 Express::
|
69
69
|
|
70
|
-
groonga-2.0
|
70
|
+
groonga-2.1.0> msbuild groonga.sln /p:Configuration=Release
|
71
71
|
|
72
72
|
Install by Visual C++ 2010 Express::
|
73
73
|
|
74
|
-
groonga-2.0
|
74
|
+
groonga-2.1.0> msbuild groonga.sln /p:Configuration=Release /t:Install
|
75
75
|
|
76
76
|
If you installed Visual Studio 2010, use can use devenv instead.
|
77
77
|
|
78
78
|
Build by Visual Studio 2010::
|
79
79
|
|
80
|
-
groonga-2.0
|
80
|
+
groonga-2.1.0> devenv groonga.sln /Build Release
|
81
81
|
|
82
82
|
Install by Visual Studio 2010::
|
83
83
|
|
84
|
-
groonga-2.0
|
84
|
+
groonga-2.1.0> devenv groonga.sln /Build Release /Project Install
|
85
85
|
|
86
86
|
After the above steps, :doc:`/reference/executables/groonga` is found in
|
87
87
|
``c:\groonga\bin\groonga.exe``.
|
@@ -5,6 +5,65 @@
|
|
5
5
|
News
|
6
6
|
====
|
7
7
|
|
8
|
+
.. _release-2-1-0:
|
9
|
+
|
10
|
+
Release 2.1.0 - 2012/12/29
|
11
|
+
--------------------------
|
12
|
+
|
13
|
+
.. Caution::
|
14
|
+
|
15
|
+
This release has backward incompatible changes against ``table_list`` and
|
16
|
+
``column_list`` commands. If you use own program which depends on the output
|
17
|
+
results above commands, you need to support null instead of "null" string.
|
18
|
+
|
19
|
+
This release has supported ``--normalizer`` option, but there is side effect for
|
20
|
+
this feature. If you open old version of groonga database at least once,
|
21
|
+
you can not open its database by old version of groonga.
|
22
|
+
|
23
|
+
There is also another backward incompatible change agaist plugin API for
|
24
|
+
tokenizer. The argument of ``grn_tokenizer_query_open`` API has changed.
|
25
|
+
This API change affects developer of tokenizer plugin.
|
26
|
+
|
27
|
+
Improvements
|
28
|
+
^^^^^^^^^^^^
|
29
|
+
|
30
|
+
* [doc] Added documentation about :ref:`nested-index-search`.
|
31
|
+
* Supported the expression as :doc:`/reference/functions/snippet_html` arguments.
|
32
|
+
This change enables you to use ``snippet_html("STRING" + "STRING")`` for example.
|
33
|
+
You can specify column name or literal for "STRING". [Reported by Tomoatsu Shimada]
|
34
|
+
* Supported to create own normalizer as a plugin.
|
35
|
+
* Moved ``groonga-query-log-analyzer`` as
|
36
|
+
`groonga-query-log <http://rubygems.org/gems/groonga-query-log>`_ RubyGems.
|
37
|
+
It enables you to analyze query logs without installing groonga package.
|
38
|
+
* Supported ``--normalizer`` option for :doc:`/reference/commands/table_create` command.
|
39
|
+
This change enables you to specify normalizer plugin.
|
40
|
+
* Changed "null" string to null value as meaning for "No Object".
|
41
|
+
This is backward incompatible change and affects output results of introspection
|
42
|
+
related commands such as ``table_list`` and ``column_list``.
|
43
|
+
* Added a flag which controls behavior about normalizer as the last argument
|
44
|
+
of ``grn_tokenizer_query_open`` API.
|
45
|
+
* Supported continuous line in command list.
|
46
|
+
* Improved to support not only no key table, but also hash table, patricia trie
|
47
|
+
and double array trie for :ref:`nested-index-search`.
|
48
|
+
|
49
|
+
Fixes
|
50
|
+
^^^^^
|
51
|
+
|
52
|
+
* [windows] Added missing ``O_BINARY`` flag to open file correctly.
|
53
|
+
This change fixes the infinite loop problem about groonga HTTP server.
|
54
|
+
[GitHub#47] [Patch by Shimomura Tatsuya]
|
55
|
+
* Fixed a bug that ``--default-match-escalation-threshold`` doesn't accept
|
56
|
+
negative value to disable functionality.
|
57
|
+
This fix enable you to disable search escalation.
|
58
|
+
see :option:`--default-match-escalation-threshold` about details.
|
59
|
+
* Fixed a bug that ``_score`` after "*" is ignored in ``--output_columns``.
|
60
|
+
|
61
|
+
Thanks
|
62
|
+
^^^^^^
|
63
|
+
|
64
|
+
* Tomoatsu Shimada
|
65
|
+
* Shimomura Tatsuya
|
66
|
+
|
8
67
|
.. _release-2-0-9:
|
9
68
|
|
10
69
|
Release 2.0.9 - 2012/11/29
|
@@ -83,6 +83,135 @@ match_columnsオプションで、検索対象のカラムを複数指定する
|
|
83
83
|
|
84
84
|
.. TODO: match_columnsにインデックス名を指定しての検索についても触れる。
|
85
85
|
|
86
|
+
|
87
|
+
.. _nested-index-search:
|
88
|
+
|
89
|
+
Nested index search among related table by column index
|
90
|
+
--------------------------------------------------------
|
91
|
+
|
92
|
+
If there are relationships among multiple table with column index,
|
93
|
+
you can search multiple table by specifying reference column name.
|
94
|
+
|
95
|
+
Here is the concrete example.
|
96
|
+
|
97
|
+
There are tables which store blog articles, comments for articles.
|
98
|
+
The table which stores articles has columns for article and comment.
|
99
|
+
And the comment column refers Comments table.
|
100
|
+
The table which stores comments has columns for comment and column index to article table.
|
101
|
+
|
102
|
+
if you want to search the articles which contain specified keyword in comment,
|
103
|
+
you need to execute fulltext search for table of comment, then search the records which contains fulltext search results.
|
104
|
+
|
105
|
+
But, you can search the records by specifying the reference column index at once.
|
106
|
+
|
107
|
+
Here is the sample schema.
|
108
|
+
|
109
|
+
.. groonga-command
|
110
|
+
.. include:: ../example/tutorial/match_columns-nested-index-schema.log
|
111
|
+
.. table_create Comments TABLE_HASH_KEY UInt32
|
112
|
+
.. column_create Comments content COLUMN_SCALAR ShortText
|
113
|
+
.. table_create Articles TABLE_NO_KEY
|
114
|
+
.. column_create Articles content COLUMN_SCALAR Text
|
115
|
+
.. column_create Articles comment COLUMN_SCALAR Comments
|
116
|
+
.. table_create Lexicon TABLE_PAT_KEY|KEY_NORMALIZE ShortText --default_tokenizer TokenBigram
|
117
|
+
.. column_create Lexicon articles_content COLUMN_INDEX|WITH_POSITION Articles content
|
118
|
+
.. column_create Lexicon comments_content COLUMN_INDEX|WITH_POSITION Comments content
|
119
|
+
.. column_create Comments article COLUMN_INDEX Articles comment
|
120
|
+
|
121
|
+
Here is the sample data.
|
122
|
+
|
123
|
+
.. groonga-command
|
124
|
+
.. include:: ../example/tutorial/match_columns-nested-index-data.log
|
125
|
+
.. load --table Comments
|
126
|
+
.. [
|
127
|
+
.. {"_key": 1, "content": "I'm using groonga too!"},
|
128
|
+
.. {"_key": 2, "content": "I'm using groonga and mroonga!"},
|
129
|
+
.. {"_key": 3, "content": "I'm using mroonga too!"}
|
130
|
+
.. ]
|
131
|
+
.. load --table Articles
|
132
|
+
.. [
|
133
|
+
.. {"content": "Groonga is fast!", "comment": 1},
|
134
|
+
.. {"content": "Groonga is useful!"},
|
135
|
+
.. {"content": "Mroonga is fast!", "comment": 3}
|
136
|
+
.. ]
|
137
|
+
|
138
|
+
You can write the query that search the records which contains specified keyword as a comment, then fetch the articles which refers to it.
|
139
|
+
|
140
|
+
Query for searching the records described above::
|
141
|
+
|
142
|
+
select Articles --match_columns comment.content --query groonga --output_columns "_id, _score, *"
|
143
|
+
|
144
|
+
You need to concatenate comment column of Articles table and content column of Comments table with period(.) as --match_columns arguments.
|
145
|
+
|
146
|
+
At first, this query execute fulltext search from content of Comments table, then fetch the records of Articles table which refers to already searched records of Comments table.
|
147
|
+
(Because of this, if you comment out the query which create column index 'article' of Comments table, you can't get intended search results.)
|
148
|
+
|
149
|
+
.. groonga-command
|
150
|
+
.. include:: ../example/tutorial/match_columns-nested-index-select.log
|
151
|
+
.. select Articles --match_columns comment.content --query groonga --output_columns "_id, _score, *"
|
152
|
+
|
153
|
+
Now, you can search articles which contains specific keywords as a comment.
|
154
|
+
|
155
|
+
The feature of nested index search is not limited to the relationship between two table only.
|
156
|
+
|
157
|
+
Here is the sample schema similar to previous one. The difference is added table which express 'Reply' and relationship is extended to three tables.
|
158
|
+
|
159
|
+
.. groonga-command
|
160
|
+
.. include:: ../example/tutorial/match_columns-nested-index-schema-with-three-relationship.log
|
161
|
+
.. table_create Replies2 TABLE_HASH_KEY UInt32
|
162
|
+
.. column_create Replies2 content COLUMN_SCALAR ShortText
|
163
|
+
.. table_create Comments2 TABLE_HASH_KEY UInt32
|
164
|
+
.. column_create Comments2 content COLUMN_SCALAR ShortText
|
165
|
+
.. column_create Comments2 comment COLUMN_SCALAR Replies2
|
166
|
+
.. table_create Articles2 TABLE_NO_KEY
|
167
|
+
.. column_create Articles2 content COLUMN_SCALAR Text
|
168
|
+
.. column_create Articles2 comment COLUMN_SCALAR Comments2
|
169
|
+
.. table_create Lexicon2 TABLE_PAT_KEY|KEY_NORMALIZE ShortText --default_tokenizer TokenBigram
|
170
|
+
.. column_create Lexicon2 articles_content COLUMN_INDEX|WITH_POSITION Articles2 content
|
171
|
+
.. column_create Lexicon2 comments_content COLUMN_INDEX|WITH_POSITION Comments2 content
|
172
|
+
.. column_create Lexicon2 replies_content COLUMN_INDEX|WITH_POSITION Replies2 content
|
173
|
+
.. column_create Comments2 article COLUMN_INDEX Articles2 comment
|
174
|
+
.. column_create Replies2 reply_to COLUMN_INDEX Comments2 comment
|
175
|
+
|
176
|
+
Here is the sample data.
|
177
|
+
|
178
|
+
.. groonga-command
|
179
|
+
.. include:: ../example/tutorial/match_columns-nested-index-data-with-three-relationship.log
|
180
|
+
.. load --table Replies2
|
181
|
+
.. [
|
182
|
+
.. {"_key": 1, "content": "I'm using rroonga too!"},
|
183
|
+
.. {"_key": 2, "content": "I'm using groonga and mroonga and rroonga!"},
|
184
|
+
.. {"_key": 3, "content": "I'm using nroonga too!"}
|
185
|
+
.. ]
|
186
|
+
.. load --table Comments2
|
187
|
+
.. [
|
188
|
+
.. {"_key": 1, "content": "I'm using groonga too!", "comment": 1},
|
189
|
+
.. {"_key": 2, "content": "I'm using groonga and mroonga!", "comment": 2},
|
190
|
+
.. {"_key": 3, "content": "I'm using mroonga too!"}
|
191
|
+
.. ]
|
192
|
+
.. load --table Articles2
|
193
|
+
.. [
|
194
|
+
.. {"content": "Groonga is fast!", "comment": 1},
|
195
|
+
.. {"content": "Groonga is useful!", "comment": 2},
|
196
|
+
.. {"content": "Mroonga is fast!", "comment": 3}
|
197
|
+
.. ]
|
198
|
+
|
199
|
+
Query for searching the records described above::
|
200
|
+
|
201
|
+
select Articles2 --match_columns comment.content --query mroonga --output_columns "_id, _score, *"
|
202
|
+
select Articles2 --match_columns comment.comment.content --query mroonga --output_columns "_id, _score, *"
|
203
|
+
|
204
|
+
The first query searches 'mroonga' from Comments2 table, the second one searches 'mroonga' from Replies2 and Comment2 table by using reference column index.
|
205
|
+
|
206
|
+
.. groonga-command
|
207
|
+
.. include:: ../example/tutorial/match_columns-nested-index-select-with-three-relationship.log
|
208
|
+
.. select Articles2 --match_columns comment.content --query mroonga --output_columns "_id, _score, *"
|
209
|
+
.. select Articles2 --match_columns comment.comment.content --query mroonga --output_columns "_id, _score, *"
|
210
|
+
|
211
|
+
As a result, the first query matches two article because of Comments2 table has two records which contains 'mroonga' as keyword.
|
212
|
+
|
213
|
+
On the other hand, the second one matches one article only because of Replies2 table has only one record which contains 'mroonga' as keyword, and there is one record which contains same keyword and refers to the record in Comments2 table.
|
214
|
+
|
86
215
|
インデックスの重み
|
87
216
|
------------------
|
88
217
|
|
@@ -1,4 +1,4 @@
|
|
1
|
-
.TH "GROONGA" "1" "2012 年
|
1
|
+
.TH "GROONGA" "1" "2012 年 12 月 27 日" "2.1.0" "groonga"
|
2
2
|
.SH NAME
|
3
3
|
groonga \- groongaのドキュメント
|
4
4
|
.
|
@@ -92,16 +92,16 @@ groonga は独自のカラムストアを持つ列指向のデータベースと
|
|
92
92
|
32\-bit用と64\-bit用のパッケージを配布していますが、サーバ用途には64\-bitパッケージを利用することをオススメします。32\-bit用パッケージはテスト用か開発用にだけ使って下さい。32\-bit用パッケージを使った場合は、中程度のサイズのデータでもメモリ不足エラーになることがあります。
|
93
93
|
.SS インストーラー
|
94
94
|
.sp
|
95
|
-
32\-bit環境の場合は \fI\%groonga-2.0
|
95
|
+
32\-bit環境の場合は \fI\%groonga-2.1.0-x86.exe\fP をダウンロードして実行してください。
|
96
96
|
.sp
|
97
|
-
64\-bit環境の場合は \fI\%groonga-2.0
|
97
|
+
64\-bit環境の場合は \fI\%groonga-2.1.0-x64.exe\fP をダウンロードして実行してください。
|
98
98
|
.sp
|
99
99
|
スタートメニュー内に \fB/reference/executables/groonga\fP 用のコマンドプロンプトがインストールされるのでそれを使ってください。
|
100
100
|
.SS zip
|
101
101
|
.sp
|
102
|
-
32\-bit環境の場合は \fI\%groonga-2.0
|
102
|
+
32\-bit環境の場合は \fI\%groonga-2.1.0-x86.zip\fP をダウンロードして展開してください。
|
103
103
|
.sp
|
104
|
-
64\-bit環境の場合は \fI\%groonga-2.0
|
104
|
+
64\-bit環境の場合は \fI\%groonga-2.1.0-x64.zip\fP をダウンロードして展開してください。
|
105
105
|
.sp
|
106
106
|
\fB/reference/executables/groonga\fP は \fBbin\fP フォルダーにあります。
|
107
107
|
.SS ソースからビルド
|
@@ -118,13 +118,13 @@ groonga は独自のカラムストアを持つ列指向のデータベースと
|
|
118
118
|
.UNINDENT
|
119
119
|
.UNINDENT
|
120
120
|
.sp
|
121
|
-
zipでアーカイブされたソース \fI\%groonga-2.0.
|
121
|
+
zipでアーカイブされたソース \fI\%groonga-2.1.0.zip\fP をダウンロードして展開します。
|
122
122
|
.sp
|
123
123
|
Microsoft Visual Studio 2010 Expressがインストールする \fBVisual Studio コマンド プロンプト (2010)\fP を実行して、groongaのソースがあるフォルダーへ移動してください:
|
124
124
|
.sp
|
125
125
|
.nf
|
126
126
|
.ft C
|
127
|
-
> cd c:\eUsers\e%USERNAME%\eDownloads\egroonga\-2.0
|
127
|
+
> cd c:\eUsers\e%USERNAME%\eDownloads\egroonga\-2.1.0
|
128
128
|
.ft P
|
129
129
|
.fi
|
130
130
|
.sp
|
@@ -132,7 +132,7 @@ Microsoft Visual Studio 2010 Expressがインストールする \fBVisual Studio
|
|
132
132
|
.sp
|
133
133
|
.nf
|
134
134
|
.ft C
|
135
|
-
groonga\-2.0
|
135
|
+
groonga\-2.1.0> cmake . \-G "Visual Studio 10 Win64" \-DCMAKE_INSTALL_PREFIX=C:\egroonga
|
136
136
|
.ft P
|
137
137
|
.fi
|
138
138
|
.sp
|
@@ -140,7 +140,7 @@ Visual C++ 2010 Expressでビルドします:
|
|
140
140
|
.sp
|
141
141
|
.nf
|
142
142
|
.ft C
|
143
|
-
groonga\-2.0
|
143
|
+
groonga\-2.1.0> msbuild groonga.sln /p:Configuration=Release
|
144
144
|
.ft P
|
145
145
|
.fi
|
146
146
|
.sp
|
@@ -148,7 +148,7 @@ Visual C++ 2010 Expressでビルドします:
|
|
148
148
|
.sp
|
149
149
|
.nf
|
150
150
|
.ft C
|
151
|
-
groonga\-2.0
|
151
|
+
groonga\-2.1.0> msbuild groonga.sln /p:Configuration=Release /t:Install
|
152
152
|
.ft P
|
153
153
|
.fi
|
154
154
|
.sp
|
@@ -158,7 +158,7 @@ Visual Studio 2010でビルドします:
|
|
158
158
|
.sp
|
159
159
|
.nf
|
160
160
|
.ft C
|
161
|
-
groonga\-2.0
|
161
|
+
groonga\-2.1.0> devenv groonga.sln /Build Release
|
162
162
|
.ft P
|
163
163
|
.fi
|
164
164
|
.sp
|
@@ -166,7 +166,7 @@ Visual Studio 2010でインストールします:
|
|
166
166
|
.sp
|
167
167
|
.nf
|
168
168
|
.ft C
|
169
|
-
groonga\-2.0
|
169
|
+
groonga\-2.1.0> devenv groonga.sln /Build Release /Project Install
|
170
170
|
.ft P
|
171
171
|
.fi
|
172
172
|
.sp
|
@@ -202,9 +202,9 @@ groonga\-2.0.9> devenv groonga.sln /Build Release /Project Install
|
|
202
202
|
.sp
|
203
203
|
.nf
|
204
204
|
.ft C
|
205
|
-
% curl \-O http://packages.groonga.org/source/groonga/groonga\-2.0.
|
206
|
-
% tar xvzf groonga\-2.0.
|
207
|
-
% cd groonga\-2.0
|
205
|
+
% curl \-O http://packages.groonga.org/source/groonga/groonga\-2.1.0.tar.gz
|
206
|
+
% tar xvzf groonga\-2.1.0.tar.gz
|
207
|
+
% cd groonga\-2.1.0
|
208
208
|
.ft P
|
209
209
|
.fi
|
210
210
|
.sp
|
@@ -379,9 +379,9 @@ groongaをビルドするために必要なパッケージをインストール
|
|
379
379
|
.sp
|
380
380
|
.nf
|
381
381
|
.ft C
|
382
|
-
% wget http://packages.groonga.org/source/groonga/groonga\-2.0.
|
383
|
-
% tar xvzf groonga\-2.0.
|
384
|
-
% cd groonga\-2.0
|
382
|
+
% wget http://packages.groonga.org/source/groonga/groonga\-2.1.0.tar.gz
|
383
|
+
% tar xvzf groonga\-2.1.0.tar.gz
|
384
|
+
% cd groonga\-2.1.0
|
385
385
|
.ft P
|
386
386
|
.fi
|
387
387
|
.sp
|
@@ -466,59 +466,6 @@ groonga\-munin\-pluginsパッケージのインストール:
|
|
466
466
|
% sudo apt\-get \-y install groonga\-munin\-plugins
|
467
467
|
.ft P
|
468
468
|
.fi
|
469
|
-
.SS 11.04 Natty Narwhal
|
470
|
-
.IP ノート
|
471
|
-
groongaをインストールするためにuniverseリポジトリを有効にしてください:
|
472
|
-
.sp
|
473
|
-
.nf
|
474
|
-
.ft C
|
475
|
-
% sudo cp /etc/apt/sources.list /etc/apt/sources.list.d/universe.list
|
476
|
-
% sudo sed \-i\(aq\(aq \-e \(aqs/main/universe/\(aq /etc/apt/sources.list.d/universe.list
|
477
|
-
.ft P
|
478
|
-
.fi
|
479
|
-
.RE
|
480
|
-
.sp
|
481
|
-
groongaのaptリポジトリを追加します。
|
482
|
-
.sp
|
483
|
-
/etc/apt/sources.list.d/groonga.list:
|
484
|
-
.sp
|
485
|
-
.nf
|
486
|
-
.ft C
|
487
|
-
deb http://packages.groonga.org/ubuntu/ natty universe
|
488
|
-
deb\-src http://packages.groonga.org/ubuntu/ natty universe
|
489
|
-
.ft P
|
490
|
-
.fi
|
491
|
-
.sp
|
492
|
-
インストール:
|
493
|
-
.sp
|
494
|
-
.nf
|
495
|
-
.ft C
|
496
|
-
% sudo apt\-get update
|
497
|
-
% sudo apt\-get \-y \-\-allow\-unauthenticated install groonga\-keyring
|
498
|
-
% sudo apt\-get update
|
499
|
-
% sudo apt\-get \-y install groonga
|
500
|
-
.ft P
|
501
|
-
.fi
|
502
|
-
.sp
|
503
|
-
\fI\%MeCab\fP をトークナイザーとして使いたいときは、groonga\-tokenizer\-mecabパッケージをインストールしてください。
|
504
|
-
.sp
|
505
|
-
groonga\-tokenizer\-mecabパッケージのインストール:
|
506
|
-
.sp
|
507
|
-
.nf
|
508
|
-
.ft C
|
509
|
-
% sudo apt\-get \-y install groonga\-tokenizer\-mecab
|
510
|
-
.ft P
|
511
|
-
.fi
|
512
|
-
.sp
|
513
|
-
\fI\%Munin\fP プラグインを提供するパッケージもあります。Muninでgroongaの状態をモニターしたい場合は、groonga\-munin\-pluginsパッケージをインストールしてください。
|
514
|
-
.sp
|
515
|
-
groonga\-munin\-pluginsパッケージのインストール:
|
516
|
-
.sp
|
517
|
-
.nf
|
518
|
-
.ft C
|
519
|
-
% sudo apt\-get \-y install groonga\-munin\-plugins
|
520
|
-
.ft P
|
521
|
-
.fi
|
522
469
|
.SS 11.10 Oneiric Ocelot
|
523
470
|
.IP ノート
|
524
471
|
groongaをインストールするためにuniverseリポジトリを有効にしてください:
|
@@ -692,9 +639,9 @@ groongaをビルドするために必要なパッケージをインストール
|
|
692
639
|
.sp
|
693
640
|
.nf
|
694
641
|
.ft C
|
695
|
-
% wget http://packages.groonga.org/source/groonga/groonga\-2.0.
|
696
|
-
% tar xvzf groonga\-2.0.
|
697
|
-
% cd groonga\-2.0
|
642
|
+
% wget http://packages.groonga.org/source/groonga/groonga\-2.1.0.tar.gz
|
643
|
+
% tar xvzf groonga\-2.1.0.tar.gz
|
644
|
+
% cd groonga\-2.1.0
|
698
645
|
.ft P
|
699
646
|
.fi
|
700
647
|
.sp
|
@@ -732,7 +679,7 @@ configureを実行します( \fBconfigure\fP のオプションについては
|
|
732
679
|
.sp
|
733
680
|
.nf
|
734
681
|
.ft C
|
735
|
-
% sudo rpm \-ivh http://packages.groonga.org/centos/groonga\-release\-1.1.0\-
|
682
|
+
% sudo rpm \-ivh http://packages.groonga.org/centos/groonga\-release\-1.1.0\-1.noarch.rpm
|
736
683
|
% sudo yum makecache
|
737
684
|
% sudo yum install \-y groonga
|
738
685
|
.ft P
|
@@ -811,7 +758,7 @@ groonga\-munin\-pluginsパッケージのインストール:
|
|
811
758
|
.sp
|
812
759
|
.nf
|
813
760
|
.ft C
|
814
|
-
% sudo rpm \-ivh http://packages.groonga.org/centos/groonga\-release\-1.1.0\-
|
761
|
+
% sudo rpm \-ivh http://packages.groonga.org/centos/groonga\-release\-1.1.0\-1.noarch.rpm
|
815
762
|
% sudo yum makecache
|
816
763
|
% sudo yum install \-y groonga
|
817
764
|
.ft P
|
@@ -853,7 +800,7 @@ EPELリポジトリを有効にする(環境非依存):
|
|
853
800
|
.sp
|
854
801
|
.nf
|
855
802
|
.ft C
|
856
|
-
% sudo rpm \-ivh http://download.fedoraproject.org/pub/epel/6/i386/epel\-release\-6\-
|
803
|
+
% sudo rpm \-ivh http://download.fedoraproject.org/pub/epel/6/i386/epel\-release\-6\-8.noarch.rpm
|
857
804
|
.ft P
|
858
805
|
.fi
|
859
806
|
.RE
|
@@ -879,9 +826,9 @@ groongaをビルドするために必要なパッケージをインストール
|
|
879
826
|
.sp
|
880
827
|
.nf
|
881
828
|
.ft C
|
882
|
-
% wget http://packages.groonga.org/source/groonga/groonga\-2.0.
|
883
|
-
% tar xvzf groonga\-2.0.
|
884
|
-
% cd groonga\-2.0
|
829
|
+
% wget http://packages.groonga.org/source/groonga/groonga\-2.1.0.tar.gz
|
830
|
+
% tar xvzf groonga\-2.1.0.tar.gz
|
831
|
+
% cd groonga\-2.1.0
|
885
832
|
.ft P
|
886
833
|
.fi
|
887
834
|
.sp
|
@@ -921,7 +868,7 @@ groonga関連のRPMパッケージはFedoraの公式yumリポジトリにもあ
|
|
921
868
|
.sp
|
922
869
|
.nf
|
923
870
|
.ft C
|
924
|
-
% sudo rpm \-ivh http://packages.groonga.org/fedora/groonga\-release\-1.1.0\-
|
871
|
+
% sudo rpm \-ivh http://packages.groonga.org/fedora/groonga\-release\-1.1.0\-1.noarch.rpm
|
925
872
|
% sudo yum update
|
926
873
|
% sudo yum install \-y groonga
|
927
874
|
.ft P
|
@@ -978,9 +925,9 @@ groongaをビルドするために必要なパッケージをインストール
|
|
978
925
|
.sp
|
979
926
|
.nf
|
980
927
|
.ft C
|
981
|
-
% wget http://packages.groonga.org/source/groonga/groonga\-2.0.
|
982
|
-
% tar xvzf groonga\-2.0.
|
983
|
-
% cd groonga\-2.0
|
928
|
+
% wget http://packages.groonga.org/source/groonga/groonga\-2.1.0.tar.gz
|
929
|
+
% tar xvzf groonga\-2.1.0.tar.gz
|
930
|
+
% cd groonga\-2.1.0
|
984
931
|
.ft P
|
985
932
|
.fi
|
986
933
|
.sp
|
@@ -1024,9 +971,9 @@ groongaをビルドするために必要なパッケージをインストール
|
|
1024
971
|
.sp
|
1025
972
|
.nf
|
1026
973
|
.ft C
|
1027
|
-
% wget http://packages.groonga.org/source/groonga/groonga\-2.0.
|
1028
|
-
% gtar xvzf groonga\-2.0.
|
1029
|
-
% cd groonga\-2.0
|
974
|
+
% wget http://packages.groonga.org/source/groonga/groonga\-2.1.0.tar.gz
|
975
|
+
% gtar xvzf groonga\-2.1.0.tar.gz
|
976
|
+
% cd groonga\-2.1.0
|
1030
977
|
.ft P
|
1031
978
|
.fi
|
1032
979
|
.sp
|
@@ -1131,9 +1078,9 @@ groongaはGNUビルドシステムを使っています。以下は一番簡単
|
|
1131
1078
|
.sp
|
1132
1079
|
.nf
|
1133
1080
|
.ft C
|
1134
|
-
% wget http://packages.groonga.org/source/groonga/groonga\-2.0.
|
1135
|
-
% tar xvzf groonga\-2.0.
|
1136
|
-
% cd groonga\-2.0
|
1081
|
+
% wget http://packages.groonga.org/source/groonga/groonga\-2.1.0.tar.gz
|
1082
|
+
% tar xvzf groonga\-2.1.0.tar.gz
|
1083
|
+
% cd groonga\-2.1.0
|
1137
1084
|
% ./configure
|
1138
1085
|
% make
|
1139
1086
|
% sudo make install
|
@@ -4951,6 +4898,304 @@ select \-\-table Blog2 \-\-match_columns title \-\-query message
|
|
4951
4898
|
.SS インデックス名を指定した全文検索
|
4952
4899
|
.sp
|
4953
4900
|
執筆中です。
|
4901
|
+
.SS カラムインデックスによる関連テーブルをまたぐ検索
|
4902
|
+
.sp
|
4903
|
+
複数のテーブルがカラムインデックスで関連付けられているなら、参照カラム名を指定して複数のテーブルにまたがって検索することができます。
|
4904
|
+
.sp
|
4905
|
+
具体的な例を示します。
|
4906
|
+
.sp
|
4907
|
+
ブログ記事や記事のコメントを保存するテーブルがあります。記事を保存するテーブルには記事とコメントのためのカラムがあります。そしてそのコメントカラムはCommentsテーブルを参照しています。コメントを保存するテーブルにはコメントと記事テーブルに対するカラムインデックスが設定されています。
|
4908
|
+
.sp
|
4909
|
+
特定のキーワードをコメントに含む記事を探すには、コメントテーブルを全文検索する必要があり、全文検索結果を含むレコードをさらに検索する必要があります。
|
4910
|
+
.sp
|
4911
|
+
しかし、カラムインデックスを指定することで一度にレコードを検索することができます。
|
4912
|
+
.sp
|
4913
|
+
サンプルのスキーマ定義はこちらです。
|
4914
|
+
.sp
|
4915
|
+
実行例:
|
4916
|
+
.sp
|
4917
|
+
.nf
|
4918
|
+
.ft C
|
4919
|
+
table_create Comments TABLE_HASH_KEY UInt32
|
4920
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
4921
|
+
column_create Comments content COLUMN_SCALAR ShortText
|
4922
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
4923
|
+
table_create Articles TABLE_NO_KEY
|
4924
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
4925
|
+
column_create Articles content COLUMN_SCALAR Text
|
4926
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
4927
|
+
column_create Articles comment COLUMN_SCALAR Comments
|
4928
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
4929
|
+
table_create Lexicon TABLE_PAT_KEY|KEY_NORMALIZE ShortText \-\-default_tokenizer TokenBigram
|
4930
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
4931
|
+
column_create Lexicon articles_content COLUMN_INDEX|WITH_POSITION Articles content
|
4932
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
4933
|
+
column_create Lexicon comments_content COLUMN_INDEX|WITH_POSITION Comments content
|
4934
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
4935
|
+
column_create Comments article COLUMN_INDEX Articles comment
|
4936
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
4937
|
+
.ft P
|
4938
|
+
.fi
|
4939
|
+
.sp
|
4940
|
+
サンプルデータはこちらです。
|
4941
|
+
.sp
|
4942
|
+
実行例:
|
4943
|
+
.sp
|
4944
|
+
.nf
|
4945
|
+
.ft C
|
4946
|
+
load \-\-table Comments
|
4947
|
+
[
|
4948
|
+
{"_key": 1, "content": "I\(aqm using groonga too!"},
|
4949
|
+
{"_key": 2, "content": "I\(aqm using groonga and mroonga!"},
|
4950
|
+
{"_key": 3, "content": "I\(aqm using mroonga too!"}
|
4951
|
+
]
|
4952
|
+
# [[0, 1337566253.89858, 0.000355720520019531], 3]
|
4953
|
+
load \-\-table Articles
|
4954
|
+
[
|
4955
|
+
{"content": "Groonga is fast!", "comment": 1},
|
4956
|
+
{"content": "Groonga is useful!"},
|
4957
|
+
{"content": "Mroonga is fast!", "comment": 3}
|
4958
|
+
]
|
4959
|
+
# [[0, 1337566253.89858, 0.000355720520019531], 3]
|
4960
|
+
.ft P
|
4961
|
+
.fi
|
4962
|
+
.sp
|
4963
|
+
特定のキーワードをコメントに含むレコードを検索するクエリを書くことができ、それによりレコードを参照する記事を取得します。
|
4964
|
+
.sp
|
4965
|
+
これまでに記述したレコードを検索するクエリ:
|
4966
|
+
.sp
|
4967
|
+
.nf
|
4968
|
+
.ft C
|
4969
|
+
select Articles \-\-match_columns comment.content \-\-query groonga \-\-output_columns "_id, _score, *"
|
4970
|
+
.ft P
|
4971
|
+
.fi
|
4972
|
+
.sp
|
4973
|
+
ArticlesテーブルのcommentカラムとCommentsテーブルのcontentカラムをピリオド(.)で連結し \fB\-\-match_columns\fP の引数とする必要があります。
|
4974
|
+
.sp
|
4975
|
+
最初に、このクエリはCommentsテーブルのcontentを全文検索し、次にCommentsテーブルを検索した結果のレコードを参照するArticlesテーブルのレコードを取得します。(これにより、Commentsテーブルの\(aqarticle\(aqカラムインデックスを生成するクエリをコメントアウトすると、意図した検索結果が得られません。)
|
4976
|
+
.sp
|
4977
|
+
実行例:
|
4978
|
+
.sp
|
4979
|
+
.nf
|
4980
|
+
.ft C
|
4981
|
+
select Articles \-\-match_columns comment.content \-\-query groonga \-\-output_columns "_id, _score, *"
|
4982
|
+
# [
|
4983
|
+
# [
|
4984
|
+
# 0,
|
4985
|
+
# 1337566253.89858,
|
4986
|
+
# 0.000355720520019531
|
4987
|
+
# ],
|
4988
|
+
# [
|
4989
|
+
# [
|
4990
|
+
# [
|
4991
|
+
# 1
|
4992
|
+
# ],
|
4993
|
+
# [
|
4994
|
+
# [
|
4995
|
+
# "_id",
|
4996
|
+
# "UInt32"
|
4997
|
+
# ],
|
4998
|
+
# [
|
4999
|
+
# "_score",
|
5000
|
+
# "Int32"
|
5001
|
+
# ],
|
5002
|
+
# [
|
5003
|
+
# "comment",
|
5004
|
+
# "Comments"
|
5005
|
+
# ],
|
5006
|
+
# [
|
5007
|
+
# "content",
|
5008
|
+
# "Text"
|
5009
|
+
# ]
|
5010
|
+
# ],
|
5011
|
+
# [
|
5012
|
+
# 1,
|
5013
|
+
# 1,
|
5014
|
+
# 1,
|
5015
|
+
# "Groonga is fast!"
|
5016
|
+
# ]
|
5017
|
+
# ]
|
5018
|
+
# ]
|
5019
|
+
# ]
|
5020
|
+
.ft P
|
5021
|
+
.fi
|
5022
|
+
.sp
|
5023
|
+
これで、特定のキーワードをコメントとして含む記事を検索できます。
|
5024
|
+
.sp
|
5025
|
+
このネストしたインデックスの検索という特徴には関連するテーブルが2つだけに制限されません。
|
5026
|
+
.sp
|
5027
|
+
前のものと似たサンプルのスキーマ定義です。違いは\(aq返信\(aqを表現するテーブルの追加と関連するテーブルが3つに増えたことです。
|
5028
|
+
.sp
|
5029
|
+
実行例:
|
5030
|
+
.sp
|
5031
|
+
.nf
|
5032
|
+
.ft C
|
5033
|
+
table_create Replies2 TABLE_HASH_KEY UInt32
|
5034
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
5035
|
+
column_create Replies2 content COLUMN_SCALAR ShortText
|
5036
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
5037
|
+
table_create Comments2 TABLE_HASH_KEY UInt32
|
5038
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
5039
|
+
column_create Comments2 content COLUMN_SCALAR ShortText
|
5040
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
5041
|
+
column_create Comments2 comment COLUMN_SCALAR Replies2
|
5042
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
5043
|
+
table_create Articles2 TABLE_NO_KEY
|
5044
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
5045
|
+
column_create Articles2 content COLUMN_SCALAR Text
|
5046
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
5047
|
+
column_create Articles2 comment COLUMN_SCALAR Comments2
|
5048
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
5049
|
+
table_create Lexicon2 TABLE_PAT_KEY|KEY_NORMALIZE ShortText \-\-default_tokenizer TokenBigram
|
5050
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
5051
|
+
column_create Lexicon2 articles_content COLUMN_INDEX|WITH_POSITION Articles2 content
|
5052
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
5053
|
+
column_create Lexicon2 comments_content COLUMN_INDEX|WITH_POSITION Comments2 content
|
5054
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
5055
|
+
column_create Lexicon2 replies_content COLUMN_INDEX|WITH_POSITION Replies2 content
|
5056
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
5057
|
+
column_create Comments2 article COLUMN_INDEX Articles2 comment
|
5058
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
5059
|
+
column_create Replies2 reply_to COLUMN_INDEX Comments2 comment
|
5060
|
+
# [[0, 1337566253.89858, 0.000355720520019531], true]
|
5061
|
+
.ft P
|
5062
|
+
.fi
|
5063
|
+
.sp
|
5064
|
+
サンプルデータはこちらです。
|
5065
|
+
.sp
|
5066
|
+
実行例:
|
5067
|
+
.sp
|
5068
|
+
.nf
|
5069
|
+
.ft C
|
5070
|
+
load \-\-table Replies2
|
5071
|
+
[
|
5072
|
+
{"_key": 1, "content": "I\(aqm using rroonga too!"},
|
5073
|
+
{"_key": 2, "content": "I\(aqm using groonga and mroonga and rroonga!"},
|
5074
|
+
{"_key": 3, "content": "I\(aqm using nroonga too!"}
|
5075
|
+
]
|
5076
|
+
# [[0, 1337566253.89858, 0.000355720520019531], 3]
|
5077
|
+
load \-\-table Comments2
|
5078
|
+
[
|
5079
|
+
{"_key": 1, "content": "I\(aqm using groonga too!", "comment": 1},
|
5080
|
+
{"_key": 2, "content": "I\(aqm using groonga and mroonga!", "comment": 2},
|
5081
|
+
{"_key": 3, "content": "I\(aqm using mroonga too!"}
|
5082
|
+
]
|
5083
|
+
# [[0, 1337566253.89858, 0.000355720520019531], 3]
|
5084
|
+
load \-\-table Articles2
|
5085
|
+
[
|
5086
|
+
{"content": "Groonga is fast!", "comment": 1},
|
5087
|
+
{"content": "Groonga is useful!", "comment": 2},
|
5088
|
+
{"content": "Mroonga is fast!", "comment": 3}
|
5089
|
+
]
|
5090
|
+
# [[0, 1337566253.89858, 0.000355720520019531], 3]
|
5091
|
+
.ft P
|
5092
|
+
.fi
|
5093
|
+
.sp
|
5094
|
+
これまでに記述したレコードを検索するクエリ:
|
5095
|
+
.sp
|
5096
|
+
.nf
|
5097
|
+
.ft C
|
5098
|
+
select Articles2 \-\-match_columns comment.content \-\-query mroonga \-\-output_columns "_id, _score, *"
|
5099
|
+
select Articles2 \-\-match_columns comment.comment.content \-\-query mroonga \-\-output_columns "_id, _score, *"
|
5100
|
+
.ft P
|
5101
|
+
.fi
|
5102
|
+
.sp
|
5103
|
+
最初のクエリはComments2テーブルから\(aqmroonga\(aqを検索します。2つめのクエリはReplies2とComments2テーブルからカラムインデックスによる参照を用いて\(aqmroonga\(aqを検索します。
|
5104
|
+
.sp
|
5105
|
+
実行例:
|
5106
|
+
.sp
|
5107
|
+
.nf
|
5108
|
+
.ft C
|
5109
|
+
select Articles2 \-\-match_columns comment.content \-\-query mroonga \-\-output_columns "_id, _score, *"
|
5110
|
+
# [
|
5111
|
+
# [
|
5112
|
+
# 0,
|
5113
|
+
# 1337566253.89858,
|
5114
|
+
# 0.000355720520019531
|
5115
|
+
# ],
|
5116
|
+
# [
|
5117
|
+
# [
|
5118
|
+
# [
|
5119
|
+
# 2
|
5120
|
+
# ],
|
5121
|
+
# [
|
5122
|
+
# [
|
5123
|
+
# "_id",
|
5124
|
+
# "UInt32"
|
5125
|
+
# ],
|
5126
|
+
# [
|
5127
|
+
# "_score",
|
5128
|
+
# "Int32"
|
5129
|
+
# ],
|
5130
|
+
# [
|
5131
|
+
# "comment",
|
5132
|
+
# "Comments2"
|
5133
|
+
# ],
|
5134
|
+
# [
|
5135
|
+
# "content",
|
5136
|
+
# "Text"
|
5137
|
+
# ]
|
5138
|
+
# ],
|
5139
|
+
# [
|
5140
|
+
# 2,
|
5141
|
+
# 1,
|
5142
|
+
# 2,
|
5143
|
+
# "Groonga is useful!"
|
5144
|
+
# ],
|
5145
|
+
# [
|
5146
|
+
# 3,
|
5147
|
+
# 1,
|
5148
|
+
# 3,
|
5149
|
+
# "Mroonga is fast!"
|
5150
|
+
# ]
|
5151
|
+
# ]
|
5152
|
+
# ]
|
5153
|
+
# ]
|
5154
|
+
select Articles2 \-\-match_columns comment.comment.content \-\-query mroonga \-\-output_columns "_id, _score, *"
|
5155
|
+
# [
|
5156
|
+
# [
|
5157
|
+
# 0,
|
5158
|
+
# 1337566253.89858,
|
5159
|
+
# 0.000355720520019531
|
5160
|
+
# ],
|
5161
|
+
# [
|
5162
|
+
# [
|
5163
|
+
# [
|
5164
|
+
# 1
|
5165
|
+
# ],
|
5166
|
+
# [
|
5167
|
+
# [
|
5168
|
+
# "_id",
|
5169
|
+
# "UInt32"
|
5170
|
+
# ],
|
5171
|
+
# [
|
5172
|
+
# "_score",
|
5173
|
+
# "Int32"
|
5174
|
+
# ],
|
5175
|
+
# [
|
5176
|
+
# "comment",
|
5177
|
+
# "Comments2"
|
5178
|
+
# ],
|
5179
|
+
# [
|
5180
|
+
# "content",
|
5181
|
+
# "Text"
|
5182
|
+
# ]
|
5183
|
+
# ],
|
5184
|
+
# [
|
5185
|
+
# 2,
|
5186
|
+
# 1,
|
5187
|
+
# 2,
|
5188
|
+
# "Groonga is useful!"
|
5189
|
+
# ]
|
5190
|
+
# ]
|
5191
|
+
# ]
|
5192
|
+
# ]
|
5193
|
+
.ft P
|
5194
|
+
.fi
|
5195
|
+
.sp
|
5196
|
+
結果として、最初のクエリはComments2テーブルに\(aqmroonga\(aqをキーワードとして含むレコードが2つあるので、該当する記事2つにマッチします。
|
5197
|
+
.sp
|
5198
|
+
一方、2つめのクエリはReplies2テーブルに\(aqmroonga\(aqというキーワードにマッチするレコードが1つしかなく、Comments2テーブルでそのキーワードを含むレコードを参照するコメントが1つなので、該当する記事は1つだけとなります。
|
4954
5199
|
.SS インデックスの重み
|
4955
5200
|
.sp
|
4956
5201
|
執筆中です。
|
@@ -19139,13 +19384,13 @@ Travis CI上でgroongaを使っているオープンソースソフトウェア
|
|
19139
19384
|
groongaプロジェクトではみなさんからのコントリビュートを歓迎します!コントリビュートの方法はいくつもあります。groongaを使ったり誰かに紹介することもコントリビュートですし、バグレポートを送ったり、groonga本体やgroonga関連の開発に参加することもコントリビュートです。プログラムではなく、ドキュメントでのコントリビュートも歓迎します!
|
19140
19385
|
.INDENT 0.0
|
19141
19386
|
.TP
|
19142
|
-
.B
|
19387
|
+
.B ユーザーの立場で:
|
19143
19388
|
このドキュメントを読んでください。
|
19144
19389
|
.TP
|
19145
|
-
.B
|
19390
|
+
.B 布教する立場で:
|
19146
19391
|
groongaについてまわりの人に話してください。
|
19147
19392
|
.TP
|
19148
|
-
.B
|
19393
|
+
.B 開発者の立場で: 不具合報告や開発、ドキュメント
|
19149
19394
|
これらについてはこのセクションで説明します。
|
19150
19395
|
.UNINDENT
|
19151
19396
|
.SS バグレポートの送り方
|