javascript - And Query on Parse Cloud code -


this looks trivial query can't seem make work.. trying instance object has locationname = "nyc" , groupname = "adults". trying query using code found on parse documentation:

    var groupquery = new parse.query("mytable");     groupquery.equalto("group", groupname);     var locationquery = new parse.query("mytable");     locationquery.equalto("location", locationname);     var mainquery = parse.query.or(locationquery, groupquery); 

but fail because using parse.query.or instead should have been parse.query.and which, reason doesn't exist... there alternative way it, reason cannot find on documentation.. cheers

parse queries use , default, why there parse.query.or(). want can achieved way :

var mainquery = new parse.query("mytable"); mainquery.equalto("group", groupname); mainquery.equalto("location", locationname); 

Comments

Popular posts from this blog

google chrome - Developer tools - How to inspect the elements which are added momentarily (by JQuery)? -

angularjs - Showing an empty as first option in select tag -

php - Cloud9 cloud IDE and CakePHP -