Closed aviL221 closed 1 year ago
Hi Yair -
My research assistant made a test function for some of the query operations and uncovered an error with the AND operator for did.query. Can you investigate and fix please?
The branch that has the test code is query_test
The test code that generates the errors here is as follows:
% this test returns an odd character string for the output of did.database.search
[b,msg] = did.test.test_did_db_queries('Do_AND_test',1,'Do_OR_test',0)
% this test succeeds fine
[b,msg] = did.test.test_did_db_queries('Do_AND_test',0,'Do_OR_test',1)
In the AND test, the result of calling did.database.search with the AND of two did.query objects is a string rather than a cell array. (The string is always something close to '0' '1' '2' '3' '4' '5' '6' '7' '8' '_' 'a' 'b' 'c' 'd' 'e' 'f')
instead of a cell array with a doc ID like {'41268c6dcd7db4d5_40c41b0f117af3e0'}
Thanks! Steve
did.test.test_did_db_queries
and its dependencies are apparently located in the query_test
branch of GitHub, whereas I'm on the sql
branch... Please update the sql branch accordingly, and I'll fix the issue
Updated!
Fixed (in the sql
branch)
Thanks, passes for me, too. All set.
Tests involving the following queries: 'and', 'or', 'exact_string', 'exact_number' May need polishing before submitting