You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
limit() is available for RangeVertexQuery, PipeVertexQuery and PipeEdgeQuery. Is it possible for limit() to be supported for predicates such as PipePropertyValueEdgeQuery, PipePropertyValueVertexQuery, PipePropertyPresenseEdgeQuery and PipePropertyPresenseVertexQuery too? Here is an example of where it may be useful:
// get all vertices of type "my_type" then get the first one with the property "Name" of value "John".let q = RangeVertexQuery::new().t(my_type).with_property_equal_to(Identifier::new("Name").unwrap(),"John".into()).limit(1)// <- get only the first vertex with the property above.outbound()// traverse onwards...
...
While I'm not familiar with rocksdb or the TAO approach, while using Tinkerpop Gremlin performance could be gained by limiting traversals where they were no longer needed. In an example such as the one above, if I'm sure that only a single vertex matches the predicate, or my query only needs a single result, then the query need not look for more vertices, and it can continue to the next step, outbound().
Another example:
// Does the property "Salary" exist on any vertex within the database?let q = PropertyPresenceVertexQuery::new(Identifier::new("Salary").unwrap()).limit(1);
The text was updated successfully, but these errors were encountered:
limit()
is available forRangeVertexQuery
,PipeVertexQuery
andPipeEdgeQuery
. Is it possible forlimit()
to be supported for predicates such asPipePropertyValueEdgeQuery
,PipePropertyValueVertexQuery
,PipePropertyPresenseEdgeQuery
andPipePropertyPresenseVertexQuery
too? Here is an example of where it may be useful:While I'm not familiar with rocksdb or the TAO approach, while using Tinkerpop Gremlin performance could be gained by limiting traversals where they were no longer needed. In an example such as the one above, if I'm sure that only a single vertex matches the predicate, or my query only needs a single result, then the query need not look for more vertices, and it can continue to the next step,
outbound()
.Another example:
The text was updated successfully, but these errors were encountered: