I have been facing problem with “Add Query Layer” in ArcGIS 10.1 (SP1). I have SQL Server Enterprise Database 2008 as backend database. When I try to add a query layer with query, Select * from <Feature Class Name>, the query doesn’t recognize the spatial field. i.e. it doesn’t read Shape field.
If I try to use advanced options for selecting the unique field, the spatial properties are grayed out (see Spatial properties snap.jpeg)
My query runs successfully but it add a table(Not a query layer) to the table of contents where the shape field gets calculated values from 1,2,3….till the number of features(see Querylayer.png snap).
When I checked the same operation with a postgres database, the query works well i.e. my shape field gets read properly.
I would be thankful if someone can suggest a solution for this weird behavior.
Thanks in anticipation.
If I try to use advanced options for selecting the unique field, the spatial properties are grayed out (see Spatial properties snap.jpeg)
My query runs successfully but it add a table(Not a query layer) to the table of contents where the shape field gets calculated values from 1,2,3….till the number of features(see Querylayer.png snap).
When I checked the same operation with a postgres database, the query works well i.e. my shape field gets read properly.
I would be thankful if someone can suggest a solution for this weird behavior.
Thanks in anticipation.