cancel
Showing results for 
Search instead for 
Did you mean: 

Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.

What's the pros of using uuid in neo4j

I'm new to neo4j and I'm trying to implementing my service on GRANDstack.

I know every node have '_id' field which is auto-incremental integer index.
But with 'neo4j-graphql-js', auto-generated schema creates nodes with uuid as a default for 'id' field.

This means newly created node should have '_id', and also 'id' which is uuid.
What's good when we have these two keys?
Does having uuid boosts performance or something?

2 REPLIES 2

'_id' is an internal Neo4j value that could be reused if nodes have been deleted. The 'id' is a unique key that your application controls. Neo4j advises not relying on the '_id' value in your code.

Ah, that makes sense. Thanks a lot!