Page 1 of 3
parse.com "where-query"
Posted: Tue Jun 19, 2012 1:29 pm
by HappyFive
hi,
i ́m using a parse.com service to store some data.
now i need to delete some data depending on the value of a local-storage-variable.
the problem is that i do not know the exact parse.com-object_id of the element i want to delete.
i only know a specific attribute of the element.
so i need something like a "where"-query. i want to delete the element "where someElementAttribute = value" and "value" is the one stored in local-storage and mapped to the request in tiggzi.
i hope you know what i mean.
thx for help
parse.com "where-query"
Posted: Tue Jun 19, 2012 1:37 pm
by maxkatz
parse.com "where-query"
Posted: Tue Jul 10, 2012 2:13 pm
by adi
Max, can you please show an example of using it. i've added a request parameter. in the Name column i've written "where" and in the value column i've written {"objectid":"P7p2BcBq4h"} - this is just an example where i'm trying to retrieve only the row who answers to this objectid. but this does not work.
parse.com "where-query"
Posted: Tue Jul 10, 2012 2:17 pm
by maxkatz
parse.com "where-query"
Posted: Tue Jul 10, 2012 5:28 pm
by adi
i have followed that article, that's exactly what i did:
X-Parse-Application-Id: xxxx
X-Parse-REST-API-Key: xxxx
where: {"objectid":"P7p2BcBq4h"}
but i get an empty return back:
{
"results": []
}
parse.com "where-query"
Posted: Tue Jul 10, 2012 5:37 pm
by maxkatz
Can you also attach a screen shot of your database from Parse?
Your key are shown in the image, you might want to reset them later.
parse.com "where-query"
Posted: Tue Jul 10, 2012 5:51 pm
by adi
parse.com "where-query"
Posted: Tue Jul 10, 2012 6:26 pm
by adi
dont worry about the keys all will go down the drain once i figure out why things are not wokring for me now
parse.com "where-query"
Posted: Tue Jul 10, 2012 6:29 pm
by maxkatz
I think in the picture, in objectId, the "I" is capital and you have it as lower case in the query (objectid).
parse.com "where-query"
Posted: Tue Jul 10, 2012 6:48 pm
by adi
i'm ashamed....sorry about that. i should have noticed it but since i tried other fields as well ( and probably did the same mistake again) i didnt catch it.