Navigation Menu

Skip to content

Commit

Permalink
Translate jsonb
Browse files Browse the repository at this point in the history
  • Loading branch information
kou committed Oct 24, 2015
1 parent 0364258 commit 823db74
Show file tree
Hide file tree
Showing 4 changed files with 150 additions and 5 deletions.
99 changes: 99 additions & 0 deletions _po/ja/reference/jsonb.po
@@ -0,0 +1,99 @@
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
"PO-Revision-Date: 2015-10-24 11:05+0900\n"
"Language: ja\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=1; plural=0;\n"

msgid ""
"---\n"
"title: jsonb support\n"
"layout: en\n"
"---"
msgstr ""
"---\n"
"title: jsonbサポート\n"
"layout: ja\n"
"---"

msgid "# `jsonb` support"
msgstr "# `jsonb`サポート"

msgid ""
"PGroonga also supports `jsonb` type. You can search JSON data by one or more k"
"eys and/or one or more values with PGroonga."
msgstr "PGroongaは`jsonb`型もサポートしています。PGroongaを使うと複数のキー・値に対して条件を指定してJSONデータを検索できます。"

msgid ""
"You can also search JSON data by full text search against all text values in J"
"SON. It's an unique feature of PGroonga. Built-in PostgreSQL features and [JsQ"
"uery](https://github.com/postgrespro/jsquery) don't support it."
msgstr ""
"JSON内のすべてのテキスト値に対して全文検索をしてJSONデータを検索することもできます。これはPostgreSQL組み込みの機能でも[JsQuery]("
"https://github.com/postgrespro/jsquery)でもサポートしていない機能です。"

msgid "Think about the following JSON:"
msgstr "次のようなJSONを考えてください。"

msgid ""
"```json\n"
"{\n"
" \"message\": \"Server is started.\",\n"
" \"host\": \"www.example.com\",\n"
" \"tags\": [\n"
" \"web\",\n"
" ]\n"
"}\n"
"```"
msgstr ""

msgid ""
"You can find the JSON by full text search with `search`, `example` or `web` be"
"cause all text values are full text search target."
msgstr ""
"`search`でも`example`でも`web`でもどの単語で全文検索してもこのJSONを検索することができます。なぜなら、すべてのテキスト値が全文検索"
"対象だからです。"

msgid "## Operators"
msgstr "## 演算子"

msgid "PGroonga provides the following two operators for searching against `jsonb`:"
msgstr "PGroongaは`jsonb`型の値で検索するために次の2つの演算子を提供しています。"

msgid ""
" * [`@>` operator](operators/jsonb-contain.html)\n"
" * [`@@` operator](operators/jsonb-query.html)"
msgstr ""
" * [`@>`演算子](operators/jsonb-contain.html)\n"
" * [`@@`演算子](operators/jsonb-query.html)"

msgid ""
"`@>` operator is simpler than `@@` operator but you can't use complex conditio"
"n such as range search."
msgstr "`@>`演算子は`@@`演算子よりもシンプルですが範囲検索のような複雑な条件を指定することはできません。"

msgid ""
"`@@` operator is more complex than `@>` operator but you can use complex condi"
"tion. You can also use full text search against all text values in JSON."
msgstr "`@@`演算子は`@>`演算子より複雑ですが、複雑な条件も使えます。JSON内のすべてのテキスト値に対する全文検索もできます。"

msgid "## Comparison with GIN"
msgstr "## GINとの比較"

msgid "PostgreSQL provides built-in fast `jsonb` search feature by GIN."
msgstr "PostgreSQLは組み込みの機能としてGINを使った高速な`jsonb`検索機能を提供しています。"

msgid "Here are differences between PGroonga and GIN:"
msgstr "PGroongaとGINの違いは次の通りです。"

msgid ""
" * Index creation time: No difference\n"
" * Search time: PGroonga is a bit faster\n"
" * Features: PGroonga provides more search features"
msgstr ""
" * インデックス作成時間:ほぼ同じ\n"
" * 検索時間:PGroongaの方が少し速い\n"
" * 機能:PGroongaの方がより多くの検索機能を提供"
45 changes: 45 additions & 0 deletions ja/reference/jsonb.md
@@ -0,0 +1,45 @@
---
title: jsonbサポート
layout: ja
---

# `jsonb`サポート

PGroongaは`jsonb`型もサポートしています。PGroongaを使うと複数のキー・値に対して条件を指定してJSONデータを検索できます。

JSON内のすべてのテキスト値に対して全文検索をしてJSONデータを検索することもできます。これはPostgreSQL組み込みの機能でも[JsQuery](https://github.com/postgrespro/jsquery)でもサポートしていない機能です。

次のようなJSONを考えてください。

```json
{
"message": "Server is started.",
"host": "www.example.com",
"tags": [
"web",
]
}
```

`search`でも`example`でも`web`でもどの単語で全文検索してもこのJSONを検索することができます。なぜなら、すべてのテキスト値が全文検索対象だからです。

## 演算子

PGroongaは`jsonb`型の値で検索するために次の2つの演算子を提供しています。

* [`@>`演算子](operators/jsonb-contain.html)
* [`@@`演算子](operators/jsonb-query.html)

`@>`演算子は`@@`演算子よりもシンプルですが範囲検索のような複雑な条件を指定することはできません。

`@@`演算子は`@>`演算子より複雑ですが、複雑な条件も使えます。JSON内のすべてのテキスト値に対する全文検索もできます。

## GINとの比較

PostgreSQLは組み込みの機能としてGINを使った高速な`jsonb`検索機能を提供しています。

PGroongaとGINの違いは次の通りです。

* インデックス作成時間:ほぼ同じ
* 検索時間:PGroongaの方が少し速い
* 機能:PGroongaの方がより多くの検索機能を提供
10 changes: 5 additions & 5 deletions ja/tutorial/index.md
Expand Up @@ -433,11 +433,11 @@ SELECT * FROM products WHERE tags %% 'PostgreSQL';

## JSONに対してPGroongaを使う方法

PGroongaは`jsonb`型にも対応しています。PGroongaを使うとJSON中のキー・値に対して検索することができます
PGroongaは`jsonb`型もサポートしています。PGroongaを使うと複数のキー・値に対して条件を指定してJSONデータを検索できます

JSON中のすべてのテキスト値に対して全文検索することもできます。これはPGroonga独自の機能です。PostgreSQL組み込みの機能でも[JsQuery](https://github.com/postgrespro/jsquery)でもこの機能はサポートしていません
JSON内のすべてのテキスト値に対して全文検索をしてJSONデータを検索することもできます。これはPostgreSQL組み込みの機能でも[JsQuery](https://github.com/postgrespro/jsquery)でもサポートしていない機能です

次のJSONを考えてください
次のようなJSONを考えてください

```json
{
Expand All @@ -449,9 +449,9 @@ JSON中のすべてのテキスト値に対して全文検索することもで
}
```

`search``example``web`のどれで全文検索してもこのJSONを見つけることができます。なぜなら、すべてのテキスト値が全文検索対象だからです。
`search`でも`example`でも`web`でもどの単語で全文検索してもこのJSONを検索することができます。なぜなら、すべてのテキスト値が全文検索対象だからです。

PGroongaは`jsonb`に対して検索するために次の2つの演算子を提供しています
PGroongaは`jsonb`型の値で検索するために次の2つの演算子を提供しています

* `@>`演算子
* `@@`演算子
Expand Down
1 change: 1 addition & 0 deletions reference/jsonb.md
Expand Up @@ -42,3 +42,4 @@ Here are differences between PGroonga and GIN:

* Index creation time: No difference
* Search time: PGroonga is a bit faster
* Features: PGroonga provides more search features

0 comments on commit 823db74

Please sign in to comment.