Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[v2][query]--Query by ambiguous filter parameter,return error result #767

Closed
yongpengli-z opened this issue Feb 22, 2024 · 1 comment
Closed
Assignees

Comments

@yongpengli-z
Copy link
Collaborator

yongpengli-z commented Feb 22, 2024

image

    @Test(description = "queryByIds",groups = {"Smoke"})
    public void queryByIds(){
        QueryResp query = milvusClientV2.query(QueryReq.builder()
                .collectionName(CommonData.defaultFloatVectorCollection)
                .consistencyLevel(ConsistencyLevel.STRONG)
                .outputFields(Lists.newArrayList("*"))
                .ids(Lists.newArrayList(1,2,3,4))
                .filter( " fieldInt64 in [10] ")
                .build());
        for (QueryResp.QueryResult queryResult : query.getQueryResults()) {
            System.out.println("查询结果fieldInt64:"+queryResult.getFields().get("fieldInt64"));

        }
        Assert.assertEquals(query.getQueryResults().size(),4);
    }
@nianliuu
Copy link
Collaborator

fixed, ids is only used when filter is null. will use filter first if it's specified

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants