<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    Olivier,<br>
    <br>
    &nbsp;I'm alpha testing the new Feature Editor within GeoMoose v2.6.&nbsp; It
    is a JavaScript application using OpenLayers 2.11, MS4W 3, and
    PostGIS 1.5 at the backend.<br>
    <br>
    &nbsp; Loading the shapefile with shp2pgsql seemed to work better than
    trying to add to an empty table with Feature Editor.&nbsp; I was able to
    display the geometry (and attributes) but saving the geometry edits
    didn't work, due to a SRS mismatch.&nbsp;&nbsp; Note that I wane to edit in
    EPSG:3857 and store the data in EPSG:4269.<br>
    <br>
    My table:<br>
    <tt><br>
      CREATE TABLE censuscities<br>
      (<br>
      &nbsp; gid serial NOT NULL,<br>
      &nbsp; statefp10 character varying(2),<br>
      &nbsp; placefp10 character varying(5),<br>
      &nbsp; placens10 character varying(8),<br>
      &nbsp; geoid10 character varying(7),<br>
      &nbsp; name10 character varying(100),<br>
      &nbsp; namelsad10 character varying(100),<br>
      &nbsp; lsad10 character varying(2),<br>
      &nbsp; classfp10 character varying(2),<br>
      &nbsp; pcicbsa10 character varying(1),<br>
      &nbsp; pcinecta10 character varying(1),<br>
      &nbsp; mtfcc10 character varying(5),<br>
      &nbsp; funcstat10 character varying(1),<br>
      &nbsp; aland10 double precision,<br>
      &nbsp; awater10 double precision,<br>
      &nbsp; intptlat10 character varying(11),<br>
      &nbsp; intptlon10 character varying(12),<br>
      &nbsp; the_geom geometry,<br>
      &nbsp; CONSTRAINT censuscities_pkey PRIMARY KEY (gid),<br>
      &nbsp; CONSTRAINT enforce_dims_the_geom CHECK (st_ndims(the_geom) = 2),<br>
      &nbsp; CONSTRAINT enforce_geotype_the_geom CHECK
      (geometrytype(the_geom) = 'MULTIPOLYGON'::text OR the_geom IS
      NULL),<br>
      &nbsp; CONSTRAINT enforce_srid_the_geom CHECK (st_srid(the_geom) =
      4269)<br>
      )<br>
      WITH (<br>
      &nbsp; OIDS=FALSE<br>
      );<br>
      ALTER TABLE censuscities OWNER TO tinyows;</tt><br>
    <br>
    ===========================================================<br>
    <br>
    My TinyOWS config.xml:<br>
    <br>
    <tt>&lt;tinyows
      online_resource=<a class="moz-txt-link-rfc2396E" href="http://thinkcentre1/cgi-bin/tinyows.exe">"http://thinkcentre1/cgi-bin/tinyows.exe"</a><br>
      &nbsp; schema_dir="/ms4w/apps/tinyows/schema/"<br>
      &nbsp; log="/ms4w/tmp/tinyows.log"<br>
      &nbsp; log_level="15"&gt;<br>
      &nbsp; &lt;pg host="127.0.0.1" user="tinyows" password="tinyows"
      dbname="tinyows_demo" port="5432"/&gt;<br>
      &nbsp; &lt;metadata name="TinyOWS Server" title="TinyOWS Server - Demo
      Service" /&gt;<br>
      <br>
      &nbsp; &lt;layer retrievable="1"<br>
      &nbsp;&nbsp;&nbsp; writable="1"<br>
      &nbsp;&nbsp;&nbsp; ns_prefix="tinyows_demo"<br>
      &nbsp;&nbsp;&nbsp; ns_uri=<a class="moz-txt-link-rfc2396E" href="http://thinkcentre1/cgi-bin/tinyows.exe">"http://thinkcentre1/cgi-bin/tinyows.exe"</a><br>
      &nbsp;&nbsp;&nbsp; name="censuscities"<br>
      &nbsp;&nbsp;&nbsp; srid="4269"<br>
      &nbsp;&nbsp;&nbsp; title="Census Cities" /&gt;<br>
      &lt;/tinyows&gt;</tt><br>
    <br>
    ===========================================================<br>
    A portion of the post sent by TinyOWS:<br>
    <br>
    <tt>&lt;gml:MultiSurface xmlns:gml=<a class="moz-txt-link-rfc2396E" href="http://www.opengis.net/gml">"http://www.opengis.net/gml"</a>
      srsName="EPSG:3857"&gt;</tt><br>
    <br>
    ===========================================================<br>
    And the error:<br>
    <br>
    <tt>&lt;?xml version='1.0' encoding='UTF-8'?&gt;<br>
      &lt;ExceptionReport<br>
      &nbsp;xmlns='<a class="moz-txt-link-freetext" href="http://www.opengis.net/ows">http://www.opengis.net/ows</a>'<br>
      &nbsp;xmlns:xsi='<a class="moz-txt-link-freetext" href="http://www.w3.org/2001/XMLSchema-instance">http://www.w3.org/2001/XMLSchema-instance</a>'<br>
      &nbsp;xsi:schemaLocation='<a class="moz-txt-link-freetext" href="http://www.opengis.net/ows">http://www.opengis.net/ows</a>
      <a class="moz-txt-link-freetext" href="http://schemas.opengis.net/ows/1.0.0/owsExceptionReport.xsd">http://schemas.opengis.net/ows/1.0.0/owsExceptionReport.xsd</a>'<br>
      &nbsp;version='1.0.0' language='en'&gt;<br>
      &nbsp;&lt;Exception exceptionCode='InvalidParameterValue'
      locator='Update'&gt;<br>
      &nbsp; &lt;ExceptionText&gt;ERROR:&nbsp; new row for relation "censuscities"
      violates check constraint "enforce_srid_the_geom"<br>
      &lt;/ExceptionText&gt;<br>
      &nbsp;&lt;/Exception&gt;<br>
      &lt;/ExceptionReport&gt;</tt><br>
    <br>
    <pre class="moz-signature" cols="72">Best Regards,
Brent Fraser</pre>
    <br>
    On 2/13/2012 4:07 PM, Olivier Courtin wrote:
    <blockquote
cite="mid:CAD+A4Nzt+iuu3ApDYawZ4p6UybBPQon_cpbREaxpEwivmx1MRg@mail.gmail.com"
      type="cite">On Sat, Feb 11, 2012 at 4:24 PM, Brent Fraser <span
        dir="ltr">&lt;<a moz-do-not-send="true"
          href="mailto:bfraser@geoanalytic.com">bfraser@geoanalytic.com</a>&gt;</span>
      wrote:<br>
      <div class="gmail_quote">
        <blockquote class="gmail_quote" style="margin:0 0 0
          .8ex;border-left:1px #ccc solid;padding-left:1ex">
          I'd like to store my data in PostGIS in EPSG:4269 (geographic)
          but edit<br>
          in EPSG:3857 (Web/Spherical Mercator ) using OpenLayers. &nbsp;Will
          TinyOSW<br>
          do the re-projection or instruct PostGIS to do a ST_Transform?<br>
        </blockquote>
        <div><br>
          WFS standard support reprojection since 1.1.0 version<br>
          So do TinyOWS <br>
          <br>
          So be carefull in your OpenLayers client to clearly specify<br>
          the right WFS version (As 1.0.0 don't support reprojection)<br>
          <br>
          HTH,<br>
        </div>
      </div>
      -- <br>
      Olivier<br>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
TinyOWS-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:TinyOWS-users@lists.maptools.org">TinyOWS-users@lists.maptools.org</a>
<a class="moz-txt-link-freetext" href="http://lists.maptools.org/mailman/listinfo/tinyows-users">http://lists.maptools.org/mailman/listinfo/tinyows-users</a>
</pre>
    </blockquote>
  </body>
</html>