Counter of Node ID

How to reset the counter of Node ID in Neo4j database?
Earlier I used to detach and delete the nodes. Then use the CSV import to add nodes to database. The counter did reset to 0.
But now it's getting incremented.
How to reset it to 0?

Hello @anshulchaintha7 :slight_smile:

You need to recreate the database:

CREATE OR REPLACE DATABASE your_database_name;

Best regards,
Cobra

1 Like