Deon,
Is it possible to help me solve this, desperate and need to find a solution. Am I being dumb? Fellow South african here
-----------------------------Distict Values with where clause on column: Server Code
Why am i getting an empty result on this distinct query?
//var getRegion = localStorage.getItem('setRegion');
var getRegion = "CENTRAL";
//console.log (getRegion);
//distinct(dbApiKey, collectionName, columnName[, queryString][, token])
var result = Collection.distinct("xxxxxxxxxx", "Reach", "SalesDistrict",{where:{"Region": "'+getRegion+'"}});
Apperyio.response.success(result, "application/json");
If I remove the where clause it retrieves all the records in the Collection. I want the Distinct values based on the Region.
Currently this gives me a result of []!
-----------------------------------------------