Daijiro MORI
null+****@clear*****
Fri Mar 8 14:08:58 JST 2013
Daijiro MORI 2013-03-08 14:08:58 +0900 (Fri, 08 Mar 2013) New Revision: 89583c03fcbc82af6f5bc15cf98f5449edc738b1 https://github.com/groonga/groonga/commit/89583c03fcbc82af6f5bc15cf98f5449edc738b1 Message: Add a test for force index zero value Added files: test/command/suite/select/index/match/zero.expected test/command/suite/select/index/match/zero.test Added: test/command/suite/select/index/match/zero.expected (+48 -0) 100644 =================================================================== --- /dev/null +++ test/command/suite/select/index/match/zero.expected 2013-03-08 14:08:58 +0900 (e88cc57) @@ -0,0 +1,48 @@ +table_create Users TABLE_HASH_KEY ShortText +[[0,0.0,0.0],true] +column_create Users age COLUMN_SCALAR Int16 +[[0,0.0,0.0],true] +table_create Ages TABLE_PAT_KEY Int16 +[[0,0.0,0.0],true] +column_create Ages users_age COLUMN_INDEX Users age +[[0,0.0,0.0],true] +load --table Users +[ +{"_key": "Alice", "age": 20}, +{"_key": "Bob", "age": 18} +] +[[0,0.0,0.0],2] +select Users --filter 'age @ 20' +[ + [ + 0, + 0.0, + 0.0 + ], + [ + [ + [ + 1 + ], + [ + [ + "_id", + "UInt32" + ], + [ + "_key", + "ShortText" + ], + [ + "age", + "Int16" + ] + ], + [ + 1, + "Alice", + 0 + ] + ] + ] +] Added: test/command/suite/select/index/match/zero.test (+14 -0) 100644 =================================================================== --- /dev/null +++ test/command/suite/select/index/match/zero.test 2013-03-08 14:08:58 +0900 (4908d7d) @@ -0,0 +1,14 @@ +table_create Users TABLE_HASH_KEY ShortText +column_create Users age COLUMN_SCALAR Int16 + +table_create Ages TABLE_PAT_KEY Int16 +column_create Ages users_age COLUMN_INDEX Users age + +load --table Users +[ +{"_key": "Alice", "age": 0}, +{"_key": "Bob", "age": 18} +] + +select Users --filter 'age @ 0' + -------------- next part -------------- HTML����������������������������... Download