When i make a query request to a map layer with some where clause to filter the response, the arcgis server truncates the where condition while executing the query on SQL server.
I am dealing with very large data set of approx 600 millions. The arcgis version is 10.4.1
The map layer is binded with a SQL view.
This is one you will likely have to work through with Esri Support. Looking at your screenshot of the REST API call, everything seems fine in terms of how you have structured the call. If the REST call is valid, the next question is how exactly the Electric Service Point layer is created. It seems like it is a view filtering a larger data set, so then what tables are involved and what is the view's SQL?
Is the GIS layer presented as a query layer using the view? This behavior occurs with my data that is a view from a non-SDE spatially enabled Oracle database where the where clause gets dropped when sorting subqueries. I believe in my case it has something to do with the uniqueID field that is used as the identifier when creating the query layer is not set up with the correct format. It has been difficult to pin down and has only allowed this data to be used in limited operations instead of across the enterprise.
Did you determine the where clause was being dropped with software such as WireShark?