couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Bonser <>
Subject Re: question about doc ids
Date Thu, 13 May 2010 13:57:18 GMT
You can make a requests to /_uuids (or /_uuids?count=100 if you want a
bunch of them) to get some random ids.

There's no guarantee that the generated IDs will be unique, but it's
very likely that they will.

On Thu, May 13, 2010 at 5:00 AM, c.Kleinhuis <> wrote:
> hello all,
> i am wondering how to generate doc ids, if for example i would like to use a
> prefix system to
> identify nodes in the database e.g. ("project-1") and "task-1" how would i
> make sure
> that the id my application generates is valid ?
> i would like to have a function like "prefix the automated id " so that i
> wouldnt have to increment
> a counter by myself, but could rely on a prefix to identify certain
> documents
> thx
> ck

Paul Bonser

View raw message