Using 10.2 Arcmap/ArcGIS Server on Windows with PostgreSQL 9.2/PostGIS 2.0. I'm try to publish a Feature Access service with all the Operations and Capabilities enabled against a purely PostGIS table (not using Esri's ST_GEOMETRY type). However, when publishing I get this blocking error during the ArcMap validation part. "00166: Layer's ObjectID is not maintained by the database and the feature service is being published with Create capability enabled" Here is the database creation script, which clearly has an auto-incrementing primary key (and editing the data outside of ArcMap proves the database is managing the ObjectID values)
CREATE SEQUENCE test_schema.mypoint_const_b_seq
INCREMENT 1
MINVALUE 1
MAXVALUE 9223372036854775807
START 1
CACHE 1;
ALTER TABLE test_schema.mypoint_const_b_seq
OWNER TO postgres;
CREATE TABLE test_schema.mypoint_const_b
(
objectid integer NOT NULL DEFAULT nextval('test_schema.mypoint_const_b_seq'::regclass),
volmon24_i integer,
site_id integer,
waterbody character varying(30),
CONSTRAINT mypoint_const_b_pkey PRIMARY KEY (objectid)
)
WITH (
OIDS=FALSE
);
SELECT AddGeometryColumn ('test_schema','mypoint_const_b','geom',4326,'MULTIPOINT',2, false);
ALTER TABLE test_schema.mypoint_const_b
OWNER TO postgres;
CREATE INDEX mypoint_const_b_geom_gist
ON test_schema.mypoint_const_b
USING gist
(geom);
What are the rules for creating PostGIS tables that ArcGIS Server 10.2 can use for publishing a Feature Access service with the Create function enabled?