What happened to definitionExpresison in 10.2 REST?

Discussion created by DavidGreene on Aug 15, 2013
Latest reply on May 12, 2014 by rcoodey
I have an iOS Runtime SDK application which was running against 10.1.1.  The app would read read the definition query from the layer so that additional filters could be added and the original query restored.  Documentation was a little confusing as to when the query would override the definition query in the map/feature service and when it would append.  In any case, we got it working.

I setup a new 10.2 server and spent an entire day wondering why I was getting "Database error: invalid query" in my server logs and the feature services were not working properly.  Some tracing with WireShark showed that the layer definitions were being set to strings like "((null) or (null)) and (status = 'Complete')".  I know I need to change the App code to not produce queries like this but that is not the source of the problem.

The real problem is that the REST endpoints no longer give the JSON "definitionExpression" parameter and the HTML format says "Definition Expression: N/A".

Has 10.2 changed so that definition queries can no longer be read or overridden?  Are REST/Runtime SDK supplied layer definitions now always evaluated in addition to the published definition query?

Thanks for any input ...