[postgis-users] FYI: Solution to Using PostGIS in ArcGIS.
MarkVolz at co.lyon.mn.us
Tue Nov 6 12:27:40 PST 2012
Recently I was struggling with getting PostGIS data in ArcGIS as a query layer. Apparently there is a bug in ArcGIS that treats every column in a query layer as a primary key. Here is the work around that I was given:
Open the ArcGIS Add Query Layer window.
Connect to your database.
Add a query and name, usually by double clicking on the table / layer name.
NOTE: DO NOT CLICK FINISH.
Validate the query.
Press "show advanced options."
The "Finish" button will change to "Next>" Press the button.
Press control and right click on any of the boxes under Unique Identifier Field(s). This will unselect all the columns
Select the actual Unique Identifier Fields - usually gid when using the PostGIS Shapefile loader.
More information about the postgis-users