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

Incorrect query results for the Gremlin API outE().hasLabel() with multiple edge labels #1969

Closed
1 task done
zhengyingying opened this issue Sep 21, 2022 · 0 comments
Closed
1 task done
Labels
bug Something isn't working

Comments

@zhengyingying
Copy link

Bug Type (问题类型)

No response

Before submit

  • 我已经确认现有的 IssuesFAQ 中没有相同 / 重复问题

Environment (环境信息)

  • Server Version: v0.12.0
  • Backend: inmemory
  • OS: xx CPUs, xx G RAM, Centos 7.x
  • Data Size: xx vertices, xx edges

Expected & Actual behavior (期望与实际表现)

The reproduce code as follows.

/** create schema */
// property
schema.propertyKey("ep0").asBoolean().ifNotExist().create();
schema.propertyKey("ep1").asBoolean().ifNotExist().create();
schema.propertyKey("vp0").asBoolean().ifNotExist().create();

// vertex
schema.vertexLabel("vl0").properties("vp0").nullableKeys("vp0").create();
schema.indexLabel("vl0Byvp0").onV("vl0").by("vp0").shard().ifNotExist().create();

// edges
schema.edgeLabel("el0").sourceLabel("vl0").targetLabel("vl0").properties("ep0").ifNotExist().create();
schema.edgeLabel("el1").sourceLabel("vl0").targetLabel("vl0").properties("ep1").ifNotExist().create();
schema.indexLabel("el0Byep0").onE("el0").by("ep0").shard().ifNotExist().create();
schema.indexLabel("el1Byep0").onE("el1").by("ep1").shard().ifNotExist().create();

/** create graph data */
Vertex vertex1 = new Vertex("vl0").property("vp0", true);
Vertex vertex2 = new Vertex("vl0").property("vp0", false);
Vertex vertex3 = new Vertex("vl0").property("vp0", true);
graph.addVertices(Arrays.asList(vertex1, vertex2, vertex3));

Edge edge1 = new Edge("el0").source(vertex1).target(vertex2).property("ep0", true);
Edge edge2 = new Edge("el1").source(vertex1).target(vertex3).property("ep1", false);
graph.addEdges(Arrays.asList(edge1, edge2));

We create three vertices and two edges.

When we execute the query g.V().outE('el0','el1').hasLabel('el0'), we expect the edge edge1 can be obtained. However, an exception Illegal key 'LABEL' with more than one value was thrown.

We find that a closed issue (#1735) reported the same bug, and it seems to be fixed. Unfortunately, we still find the same bug. Maybe it deserves further investigation?

Vertex/Edge example (问题点 / 边数据举例)

No response

Schema [VertexLabel, EdgeLabel, IndexLabel] (元数据结构)

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant