couchdb -i
DbName = <<"database_name_here">>,
DocId = <<>>,
rr(couchdb),
{ok, Db} = couch_db:open(DbName, [{user_ctx, #user_ctx{roles=[<<"_admin">>]}}]),
case couch_db:open_doc(Db, DocId) of
{ok, Doc} ->
couch_db:update_doc(Db, Doc#doc{deleted=true}, []);
Error ->
Error
end.
>> On 09/27/2011 10:00 AM, Alexander Shorin wrote:
>>>
>>> By the way, could hovercraft[1] solve this task? No one have interested?
>>>
>>> [1] https://github.com/jchris/hovercraft
>>>
>>> --
>>>
>>>>> On 09/27/2011 08:50 AM, Mark Hahn wrote:
>>>>>
>>>>>> There is no document without _id.
>>>>>> Not true. I've managed to create a doc with a blank id also. I don't
>>>>>> remember how the bug worked that caused it, but I had to delete the db
>>>>>> to
>>>>>> get rid of it.
>>>>>>
>>>>>>
>>
>>