<HTML><BODY style="word-wrap: break-word; -khtml-nbsp-mode: space; -khtml-line-break: after-white-space; "><DIV><BR class="khtml-block-placeholder"></DIV><DIV>Hi-</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>I am trying to set up a postGIS backend to featureserver. I was previously using the DBM option, and this worked for me (it's awesome, by the way, thanks) with no problems. With postgis I am missing something, perhaps obvious, but I'm sorry that I couldn't find the answer in the archives or docs.</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>My config file looks like the example in the documentation:</DIV><DIV><FONT class="Apple-style-span" face="Courier"><BR class="khtml-block-placeholder"></FONT></DIV><DIV><FONT class="Apple-style-span" color="#000000"><FONT class="Apple-style-span" face="Courier">[metadata]</FONT></FONT></DIV><DIV><FONT class="Apple-style-span" color="#000000"><FONT class="Apple-style-span" face="Courier">default_service=GeoJSON</FONT></FONT></DIV><DIV><FONT class="Apple-style-span" color="#000000"><FONT class="Apple-style-span" face="Courier"><BR class="khtml-block-placeholder"></FONT></FONT></DIV><DIV><FONT class="Apple-style-span" color="#000000"><FONT class="Apple-style-span" face="Courier">[scribble]</FONT></FONT></DIV><DIV><FONT class="Apple-style-span" color="#000000"><FONT class="Apple-style-span" face="Courier">type=PostGIS</FONT></FONT></DIV><DIV><FONT class="Apple-style-span" color="#000000"><FONT class="Apple-style-span" face="Courier">dsn=dbname=mydata</FONT></FONT></DIV><DIV><FONT class="Apple-style-span" color="#000000"><FONT class="Apple-style-span" face="Courier">layer=mylayer</FONT></FONT></DIV><DIV><FONT class="Apple-style-span" color="#000000"><FONT class="Apple-style-span" face="Courier">fid=ogc_fid</FONT></FONT></DIV><DIV><FONT class="Apple-style-span" color="#000000"><FONT class="Apple-style-span" face="Courier">geometry=wkb_geometry</FONT></FONT></DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>I believe I have settled access and permissions issues, and I have a postGIS database called mydata, with a table called mylayer, defined as follows:</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV><FONT class="Apple-style-span" color="#000000"><FONT class="Apple-style-span" face="Courier">CREATE TABLE mylayer (ogc_fid INTEGER, wkb_geometry GEOMETRY;</FONT></FONT></DIV><DIV><FONT class="Apple-style-span" color="#000000"><FONT class="Apple-style-span" face="Courier">GRANT ALL ON TABLE mylayer TO www;</FONT></FONT></DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>The database was built using a postgis template and has the usual geometry_columns and spatial_ref_sys tables.</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>However I get the following error from the browser: </DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><FONT class="Apple-style-span" color="#000000"><FONT class="Apple-style-span" face="Courier">Error: invalid label</FONT></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><FONT class="Apple-style-span" color="#000000"><FONT class="Apple-style-span" face="Courier">Source File: <A href="https://portsmouthresponse.unh.edu/cgi/featureserver.cgi/scribble/all.json?maxfeatures=20&callback=load_list">https://portsmouthresponse.unh.edu/cgi/featureserver.cgi/scribble/all.json?maxfeatures=20&amp;callback=load_list</A></FONT></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><FONT class="Apple-style-span" color="#000000"><FONT class="Apple-style-span" face="Courier">Line: 1, Column: 11</FONT></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><FONT class="Apple-style-span" color="#000000"><FONT class="Apple-style-span" face="Courier">Source Code:</FONT></FONT></DIV><DIV style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; "><FONT class="Apple-style-span" color="#000000"><FONT class="Apple-style-span" face="Courier">{"features": []}</FONT></FONT></DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>This line is what I get if I issue the create command using curl. I'm not sure what "invalid layer" is referring to.</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>One question is: should I indeed be creating the table myself? In the DBM case, featureserver created the database in /tmp.</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>Also: I feel like the table should have more columns corresponding to the attributes of the geometric objects I am uploading, for some reason I'm not clear on how many those are or where they are coming from. I hope I have provided a clear explanation of my problem and that it is not</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV>Rob Braswell</DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV><BR class="khtml-block-placeholder"></DIV><DIV><BR class="khtml-block-placeholder"></DIV></BODY></HTML>