[postgis-users] Problem with using query layer in ArcGIS

Melpati, Muni Muni.Melpati at dot.state.fl.us
Thu Jul 5 06:57:14 PDT 2012


Hi Simon,

Thank you for helping me on this. I have no issues with accessing the tables from pgadmin III. Infact I loaded the data using Postgis shapefile loader plugin. I could see, from pgadmin III, that gid is primary key.  When I queried data from ArcMap, I checked gid column as only unique identifier field. I did not install ArcSDE on the machine. With regards to configuration. What configuration files (ArcSDE sever config file) I need to look to make sure no network issues are there? Cause the message, I get when I open the table of the queried layer in ArcMap is

"Could not load data from the data source. If you can correct the problem, press the refresh button to reload data. Possible problems can include bad network connection, invalid field, etc. The SQL statement was not a select statement. The operation is not supported by this implementation."



Any suggestions you may have? Thanks in advance.

Regards,

Muni



Can you interact with the postgresql/Postgis data natively (ie via pgAminIII) without error? Can't think of any case where this might not be the case. This smells very much like an ArcGIS/ArcSDE configuration problem. In the old days, when one used the ArcSDE administration command line tools, one would use sdelayer to create a layer over an existing table. That sdelayer command included arguments to tell ArcSDE what column contained the unique identifier and whether it was SDE maintained or user maintained. ArcSDE, back then, didn't require the column to be a primary key, only unique.



sdelayer -o add -l <table,column> -e <entity_mask> [-t <storage_type>] [Spatial_Index][{-R <SRID> | [Spatial_Ref_Opts]}] [-M <minimum_id>] [{-f <init_features,avg_points> | -k <config_keyword>}] [-E <{empty | xmin,ymin,xmax,ymax}>] [-L {ON | OFF}] [-C <row_id_column>[,{SDE|USER}[,<min_ID>]]] [-P {HIGH | BASIC}] [-S <layer_description_str>] [-i {<service> | <port#> | <direct connection>}] [-s <server_name>] [-D <database_name>] -u <DB_user_name> -p <DB_user_password> [-q]



For -C .....



Specifies the name of the row ID column of the layer's business table and the optional minimum row ID value



For the register operation, it also specifies whether the row ID is to be registered as user or ArcSDE maintained. If ArcSDE maintained, you can specify the starting value (min_ID) for the row ID. If no minimum ID is specified, it defaults to 1. If you intend to register the feature class with the geodatabase, you should register the row ID column as ArcSDE maintained.



For the feature_info operation, it specifies the name of the row ID column that will be output to a table in the database.



Double check that this is your table/column configuration aligns with what I have said.



regards

Simon

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20120705/42128a09/attachment.html>


More information about the postgis-users mailing list