Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
251 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
83 changes: 83 additions & 0 deletions
83
test/command/suite/select/drilldown/labeled/calc_types/min.expected
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,83 @@ | ||
| table_create Tags TABLE_PAT_KEY ShortText | ||
| [[0,0.0,0.0],true] | ||
| table_create Memos TABLE_HASH_KEY ShortText | ||
| [[0,0.0,0.0],true] | ||
| column_create Memos tag COLUMN_SCALAR Tags | ||
| [[0,0.0,0.0],true] | ||
| column_create Memos priority COLUMN_SCALAR Int64 | ||
| [[0,0.0,0.0],true] | ||
| load --table Memos | ||
| [ | ||
| {"_key": "Groonga1", "tag": "Groonga", "priority": 10}, | ||
| {"_key": "Groonga2", "tag": "Groonga", "priority": 20}, | ||
| {"_key": "Groonga3", "tag": "Groonga", "priority": 40}, | ||
| {"_key": "Mroonga1", "tag": "Mroonga", "priority": 50}, | ||
| {"_key": "Mroonga2", "tag": "Mroonga", "priority": 25}, | ||
| {"_key": "Mroonga3", "tag": "Mroonga", "priority": 5}, | ||
| {"_key": "Rroonga1", "tag": "Rroonga", "priority": 25}, | ||
| {"_key": "Rroonga2", "tag": "Rroonga", "priority": -25}, | ||
| {"_key": "Rroonga3", "tag": "Rroonga", "priority": 0} | ||
| ] | ||
| [[0,0.0,0.0],9] | ||
| select Memos --limit 0 --drilldown[tag].keys tag --drilldown[tag].calc_types MIN --drilldown[tag].calc_target priority --drilldown[tag].output_columns _key,_min | ||
| [ | ||
| [ | ||
| 0, | ||
| 0.0, | ||
| 0.0 | ||
| ], | ||
| [ | ||
| [ | ||
| [ | ||
| 9 | ||
| ], | ||
| [ | ||
| [ | ||
| "_id", | ||
| "UInt32" | ||
| ], | ||
| [ | ||
| "_key", | ||
| "ShortText" | ||
| ], | ||
| [ | ||
| "priority", | ||
| "Int64" | ||
| ], | ||
| [ | ||
| "tag", | ||
| "Tags" | ||
| ] | ||
| ] | ||
| ], | ||
| { | ||
| "tag": [ | ||
| [ | ||
| 3 | ||
| ], | ||
| [ | ||
| [ | ||
| "_key", | ||
| "ShortText" | ||
| ], | ||
| [ | ||
| "_min", | ||
| "Int64" | ||
| ] | ||
| ], | ||
| [ | ||
| "Groonga", | ||
| 10 | ||
| ], | ||
| [ | ||
| "Mroonga", | ||
| 5 | ||
| ], | ||
| [ | ||
| "Rroonga", | ||
| -25 | ||
| ] | ||
| ] | ||
| } | ||
| ] | ||
| ] |
25 changes: 25 additions & 0 deletions
25
test/command/suite/select/drilldown/labeled/calc_types/min.test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,25 @@ | ||
| table_create Tags TABLE_PAT_KEY ShortText | ||
|
|
||
| table_create Memos TABLE_HASH_KEY ShortText | ||
| column_create Memos tag COLUMN_SCALAR Tags | ||
| column_create Memos priority COLUMN_SCALAR Int64 | ||
|
|
||
| load --table Memos | ||
| [ | ||
| {"_key": "Groonga1", "tag": "Groonga", "priority": 10}, | ||
| {"_key": "Groonga2", "tag": "Groonga", "priority": 20}, | ||
| {"_key": "Groonga3", "tag": "Groonga", "priority": 40}, | ||
| {"_key": "Mroonga1", "tag": "Mroonga", "priority": 50}, | ||
| {"_key": "Mroonga2", "tag": "Mroonga", "priority": 25}, | ||
| {"_key": "Mroonga3", "tag": "Mroonga", "priority": 5}, | ||
| {"_key": "Rroonga1", "tag": "Rroonga", "priority": 25}, | ||
| {"_key": "Rroonga2", "tag": "Rroonga", "priority": -25}, | ||
| {"_key": "Rroonga3", "tag": "Rroonga", "priority": 0} | ||
| ] | ||
|
|
||
| select Memos \ | ||
| --limit 0 \ | ||
| --drilldown[tag].keys tag \ | ||
| --drilldown[tag].calc_types MIN \ | ||
| --drilldown[tag].calc_target priority \ | ||
| --drilldown[tag].output_columns _key,_min |