couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Davis <paul.joseph.da...@gmail.com>
Subject Re: Redefine the _id
Date Thu, 27 Jan 2011 19:46:45 GMT
Then copy your doc to the new id and delete the old one.

On Thu, Jan 27, 2011 at 2:45 PM, Fabio Batalha Cunha dos Santos
<fabio.batalha@scielo.org> wrote:
> Hi Paul,
>
> Yes This issue I now.
>
> I want to redefine an id that was already defined automatically by the
> couchDB.
> I already have a lot of register with _id as UUID, I want to change it to
> another value.
>
>
> Thanks,
> *Fabio Batalha C. Santos*
> Colegiado SciELO
> www.scielo.org
> FAPESP - CNPq - BIREME - FapUNIFESP
>
>
>
> On Thu, Jan 27, 2011 at 5:05 PM, Paul Davis <paul.joseph.davis@gmail.com>wrote:
>
>> On Thu, Jan 27, 2011 at 2:02 PM, Fabio Batalha Cunha dos Santos
>> <fabio.batalha@scielo.org> wrote:
>> > Hello all,
>> >
>> > I'd like to know if is it possible to redefine the _id value. I intend to
>> > user a different id from the automatic UUID generated by the couchdb.
>> >
>> > Thanks,
>> > *Fabio Batalha C. Santos*
>> > Colegiado SciELO
>> > www.scielo.org
>> > FAPESP - CNPq - BIREME - FapUNIFESP
>> >
>>
>> Just put to /db_name/docid or POST with an {"_id": "my_id", ...}
>>
>> Couch only generates an id when you haven't provided one.
>>
>

Mime
View raw message