How to make a UUID in DynamoDB?

后端 未结 10 1292
佛祖请我去吃肉
佛祖请我去吃肉 2020-12-01 18:17

In my db scheme, I need a autoincrement primary key. How I can realize this feature?

PS For access to DynamoDB, I use dynode, module for Node.js.

10条回答
  •  一整个雨季
    2020-12-01 18:25

    I've had the same problem and created a small web service just for this purpose. See this blog post, that explains how I'm using stateful.co with DynamoDB in order to simulate auto-increment functionality: http://www.yegor256.com/2014/05/18/cloud-autoincrement-counters.html

    Basically, you register an atomic counter at stateful.co and increment it every time you need a new value, through RESTful API. The service is free.

提交回复
热议问题