mayildiz06

Query with huge parameters.

Discussion created by mayildiz06 on Jul 17, 2013
Latest reply on Jul 21, 2013 by mayildiz06
Hi,
i have an aplication which i developped using javascript api. In my application i am using query task and querying lots of records. the problem is that my where clause is includes 'IN()' keyword. but i have 900 item in this keyword. soo even i am using proxy page this query task is fails. my code block is at the below. how can i solve this problem.
Not: i am querying from https: servers.

if (yolortahatids.length > 0) {
            var whereClause = FIELDNAME_ID + " IN (";
            for (var i = 0; i < 150; i++) {//yolortahatids.length; i++) {
                whereClause += "'" + yolortahatids[i] + "',";
            }
            whereClause = whereClause.substr(0, whereClause.length - 1);
            whereClause += ")";

            var queryyolortahat = queryrest(layerUrlYolOrtaHat, ["*"], whereClause, mapSpatialReference, true, function (featureSet) {
                if (featureSet != null && featureSet.features.length > 0) {
                    querycompleated(featureSet.features);
                }
                else
                    querycompleated(null);
            });

Outcomes