| 1 |
table_create Memos TABLE_NO_KEY |
| 2 |
column_create Memos content COLUMN_SCALAR ShortText |
| 3 |
|
| 4 |
table_create Lexicon TABLE_PAT_KEY ShortText --default_tokenizer TokenBigram |
| 5 |
column_create Lexicon diary_content COLUMN_INDEX|WITH_POSITION Memos content |
| 6 |
|
| 7 |
table_create Synonyms TABLE_PAT_KEY ShortText |
| 8 |
column_create Synonyms words COLUMN_VECTOR ShortText |
| 9 |
|
| 10 |
load --table Memos |
| 11 |
[ |
| 12 |
["content"], |
| 13 |
["Start groonga!"], |
| 14 |
["Start mroonga!"], |
| 15 |
["Start rroonga!"], |
| 16 |
["Learning Ruby and groonga..."] |
| 17 |
] |
| 18 |
|
| 19 |
load --table Synonyms |
| 20 |
[ |
| 21 |
["_key", "words"], |
| 22 |
["rroonga", ["rroonga", "groonga"]], |
| 23 |
["groonga", ["groonga", "mroonga"]] |
| 24 |
] |
| 25 |
|
| 26 |
select --table Memos --query_expander Synonyms.words \ |
| 27 |
--match_columns content --query rroonga |