简体   繁体   中英

How to reset autoincrement _key value in arangodb?

I want to reset autoincrement _key value in arangodb. How?

I do not know of a way to reset the auto increment in place. But how about:

  • creating a new collection
  • inserting all the data from the existing table , if any (without specifying the _key in the insert so the data gets a new _key).
  • Deleting the old collection (after verifying the data was properly inserting in the new table).
  • And finally, renaming the new table to the old table's name.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM