How to effectively check the existence of an edge

0

How to effectively check the existence of an edge? I tried using a query of this type:
g.V(srcId).out(edgeName).has(dstId).hasNext()
But after checking the performance, I realized that this is not an efficient query (it takes about 0.1-0.3 seconds) while extracting edges takes ~0.02

windox
feita há 3 anos188 visualizações
2 Respostas
0

I don't think this is a correct query. "has(dstId)" seems wrong, see https://tinkerpop.apache.org/docs/3.5.0/reference/#has-step . Perhaps you meant "hasId(dstId)"?

AWS
respondido há 3 anos
0

Indeed, I made a mistake... Thanks

windox
respondido há 3 anos

Você não está conectado. Fazer login para postar uma resposta.

Uma boa resposta responde claramente à pergunta, dá feedback construtivo e incentiva o crescimento profissional de quem perguntou.

Diretrizes para responder a perguntas