You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@couchdb.apache.org by Lajos Papp <la...@yahoo.com> on 2010/11/24 18:48:50 UTC

unable to delete a document as an instance wide admin

Hi guys,

Im trying to delete a document as the instance wide admin both from futon and from command line via curl,
but this is what i get:

> curl -X DELETE http://lalyos:iwonttellya@lalyos.couchone.com/somedb/someid?rev=6-e36e512fa0ffa6e5b069f210d292a9fa
{"error":"forbidden","reason":"Sorry, you can only delete your own work."}

as you can see the instance is at couchone.com, so i dont have acces to local.ini but i can see on futon's 'Configuration' page
lalyos listed as 'admins

why is the database admin not able to delete a document?

cheers,
lalyos

Re: unable to delete a document as an instance wide admin

Posted by Lajos Papp <la...@yahoo.com>.
thanks a lot Zach!

that was it. i was using the "swinger" presentation example couchapp, 
and it had a bug in the validate_doc_update function, after fixing it
i was able to delete.

cheers,
lalyos


> You could be failing a validation. Have you defined any design
> documents with a validate_doc_update function for this database?
> –Zach
> 
> On Wed, Nov 24, 2010 at 11:48 AM, Lajos Papp <la...@yahoo.com> wrote:
>> Hi guys,
>> 
>> Im trying to delete a document as the instance wide admin both from futon and from command line via curl,
>> but this is what i get:
>> 
>>> curl -X DELETE http://lalyos:iwonttellya@lalyos.couchone.com/somedb/someid?rev=6-e36e512fa0ffa6e5b069f210d292a9fa
>> {"error":"forbidden","reason":"Sorry, you can only delete your own work."}
>> 
>> as you can see the instance is at couchone.com, so i dont have acces to local.ini but i can see on futon's 'Configuration' page
>> lalyos listed as 'admins
>> 
>> why is the database admin not able to delete a document?
>> 
>> cheers,
>> lalyos


Re: unable to delete a document as an instance wide admin

Posted by Zachary Zolton <za...@gmail.com>.
You could be failing a validation. Have you defined any design
documents with a validate_doc_update function for this database?
–Zach

On Wed, Nov 24, 2010 at 11:48 AM, Lajos Papp <la...@yahoo.com> wrote:
> Hi guys,
>
> Im trying to delete a document as the instance wide admin both from futon and from command line via curl,
> but this is what i get:
>
>> curl -X DELETE http://lalyos:iwonttellya@lalyos.couchone.com/somedb/someid?rev=6-e36e512fa0ffa6e5b069f210d292a9fa
> {"error":"forbidden","reason":"Sorry, you can only delete your own work."}
>
> as you can see the instance is at couchone.com, so i dont have acces to local.ini but i can see on futon's 'Configuration' page
> lalyos listed as 'admins
>
> why is the database admin not able to delete a document?
>
> cheers,
> lalyos