Hi Alex, I&#39;m having exactly the same problem. The server responds OK, but no INSERT other than the SERIAL (INTEGER) fid. UPDATE &amp; DELETE are perfectly working. I like the simple set-up of TinyOWS very much, and I don&#39;t want to change another server @all. I&#39;m still struggling to fix it. Let&#39;s join hands, and share our ideas ab this.<br>
<br>cheers!!!<br><br><div class="gmail_quote">On Thu, Dec 17, 2009 at 6:00 PM,  <span dir="ltr">&lt;<a href="mailto:tinyows-users-request@lists.maptools.org">tinyows-users-request@lists.maptools.org</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Send TinyOWS-users mailing list submissions to<br>
        <a href="mailto:tinyows-users@lists.maptools.org">tinyows-users@lists.maptools.org</a><br>
<br>
To subscribe or unsubscribe via the World Wide Web, visit<br>
        <a href="http://lists.maptools.org/mailman/listinfo/tinyows-users" target="_blank">http://lists.maptools.org/mailman/listinfo/tinyows-users</a><br>
or, via email, send a message with subject or body &#39;help&#39; to<br>
        <a href="mailto:tinyows-users-request@lists.maptools.org">tinyows-users-request@lists.maptools.org</a><br>
<br>
You can reach the person managing the list at<br>
        <a href="mailto:tinyows-users-owner@lists.maptools.org">tinyows-users-owner@lists.maptools.org</a><br>
<br>
When replying, please edit your Subject line so it is more specific<br>
than &quot;Re: Contents of TinyOWS-users digest...&quot;<br>
<br>
<br>
Today&#39;s Topics:<br>
<br>
   1. Re: INSERT without geometry (Haftish 21)<br>
   2. Re: INSERT without geometry (Olivier Courtin)<br>
   3. Re: INSERT without geometry (Haftish 21)<br>
   4. INSERT is not working (Alexander Sch?fer)<br>
   5. Re: INSERT is not working (Olivier Courtin)<br>
<br>
<br>
----------------------------------------------------------------------<br>
<br>
Message: 1<br>
Date: Wed, 16 Dec 2009 18:32:54 +0100<br>
From: Haftish 21 &lt;<a href="mailto:haftish21@gmail.com">haftish21@gmail.com</a>&gt;<br>
Subject: Re: [TinyOWS-users] INSERT without geometry<br>
To: Olivier Courtin &lt;<a href="mailto:olivier.courtin@gmail.com">olivier.courtin@gmail.com</a>&gt;<br>
Cc: <a href="mailto:tinyows-users@lists.maptools.org">tinyows-users@lists.maptools.org</a><br>
Message-ID:<br>
        &lt;<a href="mailto:52cf5e870912160932l78b415a4l83aad7565817789d@mail.gmail.com">52cf5e870912160932l78b415a4l83aad7565817789d@mail.gmail.com</a>&gt;<br>
Content-Type: text/plain; charset=&quot;iso-8859-1&quot;<br>
<br>
It seems the problem is with the feature id TinyOWS is creating  (fid), my<br>
database table has five columns (geometry column + 4 attributes). the fid is<br>
going to the first column of my table by default. Do I have to get one<br>
column ready for fid or what?<br>
-------------- next part --------------<br>
An HTML attachment was scrubbed...<br>
URL: <a href="http://lists.maptools.org/pipermail/tinyows-users/attachments/20091216/b10088a2/attachment.html" target="_blank">http://lists.maptools.org/pipermail/tinyows-users/attachments/20091216/b10088a2/attachment.html</a><br>

<br>
------------------------------<br>
<br>
Message: 2<br>
Date: Wed, 16 Dec 2009 20:47:54 +0100<br>
From: Olivier Courtin &lt;<a href="mailto:olivier.courtin@gmail.com">olivier.courtin@gmail.com</a>&gt;<br>
Subject: Re: [TinyOWS-users] INSERT without geometry<br>
To: Haftish 21 &lt;<a href="mailto:haftish21@gmail.com">haftish21@gmail.com</a>&gt;<br>
Cc: <a href="mailto:tinyows-users@lists.maptools.org">tinyows-users@lists.maptools.org</a><br>
Message-ID: &lt;<a href="mailto:FA06AFD3-007C-4A0A-BF23-20EE11D3EB15@gmail.com">FA06AFD3-007C-4A0A-BF23-20EE11D3EB15@gmail.com</a>&gt;<br>
Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes<br>
<br>
<br>
On Dec 16, 2009, at 6:32 PM, Haftish 21 wrote:<br>
<br>
&gt;<br>
&gt; It seems the problem is with the feature id TinyOWS is creating<br>
&gt; (fid), my database table has five columns (geometry column + 4<br>
&gt; attributes). the fid is going to the first column of my table by<br>
&gt; default. Do I have to get one column ready for fid or what?<br>
<br>
<br>
Yes there&#39;s two conditions to make transactional WFS works on a<br>
PostGIS table:<br>
<br>
  1) Having a geometry column (with a correct entry in<br>
geometry_columns table)<br>
  2) Having a Primary Key column defined for the table (as serial or<br>
int type)<br>
<br>
<br>
--<br>
Olivier<br>
<br>
<br>
<br>
------------------------------<br>
<br>
Message: 3<br>
Date: Wed, 16 Dec 2009 21:51:52 +0100<br>
From: Haftish 21 &lt;<a href="mailto:haftish21@gmail.com">haftish21@gmail.com</a>&gt;<br>
Subject: Re: [TinyOWS-users] INSERT without geometry<br>
To: Olivier Courtin &lt;<a href="mailto:olivier.courtin@gmail.com">olivier.courtin@gmail.com</a>&gt;<br>
Cc: <a href="mailto:tinyows-users@lists.maptools.org">tinyows-users@lists.maptools.org</a><br>
Message-ID:<br>
        &lt;<a href="mailto:52cf5e870912161251l69004015nfe1a65d1fec9e40b@mail.gmail.com">52cf5e870912161251l69004015nfe1a65d1fec9e40b@mail.gmail.com</a>&gt;<br>
Content-Type: text/plain; charset=&quot;iso-8859-1&quot;<br>
<br>
yeha!!<br>
For my five columns inside my table I have a form which requires three<br>
entries, expecting TinyOWS will take care of the PK and the geometry<br>
columns. I&#39;ve also mapped correctly the form entries with their<br>
corresponding table attributes.<br>
<br>
However, it seems that I&#39;m not the only one who encountered this problem. I<br>
read some similar questions raised on OL &amp; TinyOWS ML. It would&#39;ve been nice<br>
had these guys share how they solved their problem. I think I should be<br>
patient and wait for the new version.<br>
<br>
Cheers!!!<br>
-------------- next part --------------<br>
An HTML attachment was scrubbed...<br>
URL: <a href="http://lists.maptools.org/pipermail/tinyows-users/attachments/20091216/f510ffd9/attachment-0001.htm" target="_blank">http://lists.maptools.org/pipermail/tinyows-users/attachments/20091216/f510ffd9/attachment-0001.htm</a><br>

<br>
------------------------------<br>
<br>
Message: 4<br>
Date: Thu, 17 Dec 2009 09:34:26 +0100<br>
From: Alexander Sch?fer &lt;<a href="mailto:alexander.schaefer@intevation.de">alexander.schaefer@intevation.de</a>&gt;<br>
Subject: [TinyOWS-users] INSERT is not working<br>
To: <a href="mailto:tinyows-users@lists.maptools.org">tinyows-users@lists.maptools.org</a><br>
Message-ID: &lt;<a href="mailto:200912170934.26759.alexander.schaefer@intevation.de">200912170934.26759.alexander.schaefer@intevation.de</a>&gt;<br>
Content-Type: text/plain;  charset=&quot;iso-8859-1&quot;<br>
<br>
Hello,<br>
<br>
I use tinyows 0.7.0/SVN Version (Revision 185) as a WFS Server with OpenLayers<br>
2.8. The update and delete feature works fine. But it is not possible for me<br>
to save newly drawn features.<br>
If I draw a polygon and save it, the request is successfully but only the id<br>
(serial PK) stored in the database and neither the geometry nor its<br>
attributes. If i reload the page all newly drawn features are gone.<br>
<br>
The only way for me to work around this is to use the update function:<br>
- Draw a new feature, save it,<br>
- update the feature and than save it again.<br>
After this the geometry with all attributes is stored. ?<br>
<br>
I tried some changes to solve the problem but nothing works:<br>
- Used WFS Version 1.1.0 and 1.0.0<br>
- Created new table with POLYGON, LINE or POINT geometrycolumn and<br>
? draw/saved corresponding features<br>
- Copied the successfully postrequest from the tinyows example<br>
? <a href="http://dev4.mapgears.com/bdga/bdgaWFS-T.html" target="_blank">http://dev4.mapgears.com/bdga/bdgaWFS-T.html</a>, fit it, and send it via<br>
? curl to my tinyows server, e.g. &quot;curl xyz&quot;<br>
<br>
My Tinyows and OpenLayers Configuration and Requests<br>
<br>
Tinyows config.xml<br>
<br>
&lt;tinyows online_resource=&quot;http://*******/cgi-bin/tinyows&quot;<br>
         schema_dir=&quot;/usr/local/tinyows/schema/&quot;<br>
         log=&quot;/tmp/tinyows.log&quot;<br>
&gt;<br>
<br>
  &lt;pg host=&quot;**********&quot; user=&quot;postgres&quot; password=&quot;********&quot;<br>
dbname=&quot;tinyows_demo<br>
&quot; port=&quot;5432&quot;/&gt;<br>
<br>
  &lt;metadata name=&quot;&quot;<br>
            title=&quot;TinyOWS Server - Demo Service&quot;/&gt;<br>
<br>
  &lt;contact name=&quot;TinyOWS Server&quot;<br>
           site=&quot;<a href="http://www.tinyows.org/" target="_blank">http://www.tinyows.org/</a>&quot;<br>
           email=&quot;<a href="mailto:tinyows-users@lists.maptools.org">tinyows-users@lists.maptools.org</a>&quot; /&gt;<br>
<br>
  &lt;layer retrievable=&quot;1&quot;<br>
         prefix=&quot;tows&quot;<br>
         server=&quot;http://*******/&quot;<br>
         name=&quot;world&quot;<br>
         title=&quot;World Administrative Boundaries&quot;/&gt;<br>
<br>
  &lt;layer retrievable=&quot;1&quot;<br>
         writeable=&quot;1&quot;<br>
         prefix=&quot;tows&quot;<br>
         server=&quot;http://**********/&quot;<br>
         name=&quot;france_linie&quot;<br>
         title=&quot;French Administrative Sub Boundaries (IGN - GeoFLA<br>
Departements)&quot;/&gt;<br>
&lt;/tinyows&gt;<br>
_____________________________________________________________<br>
<br>
OpenLayers Configuraion:<br>
<br>
 var saveStrategy = new OpenLayers.Strategy.Save();<br>
<br>
            var wfs = new OpenLayers.Layer.Vector(&quot;France&quot;, {<br>
                strategies: [new OpenLayers.Strategy.BBOX(), saveStrategy],<br>
                protocol: new OpenLayers.Protocol.WFS({<br>
                    version: &quot;1.0.0&quot;,<br>
                    url: &quot;http://********/cgi-bin/tinyows&quot;,<br>
                    featureType: &quot;france_linie&quot;,<br>
                    featureNS: &quot;http://*******/tows&quot;,<br>
                    geometryName: &quot;the_geom&quot;,<br>
                    schema: &quot;http://******/cgi-bin/tinyows?service=WFS&amp;versio<br>
n=1.0.0&amp;request=DescribeFeatureType&amp;TypeName=france_linie&quot;,<br>
                })<br>
<br>
          });<br>
--------------------------------------------------------------------------------------------<br>
<br>
onclick to save function from openlayers example:<br>
<br>
<a href="http://openlayers.org/dev/examples/wfs-protocol-transactions.html" target="_blank">http://openlayers.org/dev/examples/wfs-protocol-transactions.html</a><br>
<br>
var DeleteFeature = OpenLayers.Class(OpenLayers.Control, {<br>
            initialize: function(layer, options) {<br>
                OpenLayers.Control.prototype.initialize.apply(this,<br>
[options]);<br>
                this.layer = layer;<br>
                this.handler = new OpenLayers.Handler.Feature(<br>
                    this, layer, {click: this.clickFeature}<br>
                );<br>
            },<br>
            clickFeature: function(feature) {<br>
                // if feature doesn&#39;t have a fid, destroy it<br>
                if(feature.fid == undefined) {<br>
                    this.layer.destroyFeatures([feature]);<br>
                } else {<br>
                    feature.state = OpenLayers.State.DELETE;<br>
                    this.layer.events.triggerEvent(&quot;afterfeaturemodified&quot;,<br>
                                                   {feature: feature});<br>
                    feature.renderIntent = &quot;select&quot;;<br>
                    this.layer.drawFeature(feature);<br>
                }<br>
            },<br>
            setMap: function(map) {<br>
                this.handler.setMap(map);<br>
                OpenLayers.Control.prototype.setMap.apply(this, arguments);<br>
            },<br>
            CLASS_NAME: &quot;OpenLayers.Control.DeleteFeature&quot;<br>
        });<br>
<br>
____________________________________________________________________<br>
<br>
Insert Request which is only store the id but not the attributes<br>
<br>
Geometry: Linestring<br>
<br>
WFS Version 1.0.0<br>
<br>
Insert Request<br>
<br>
POST:<br>
<br>
&lt;?xml version=&quot;1.0&quot;?&gt;<br>
&lt;wfs:Transaction xmlns:wfs=&quot;<a href="http://www.opengis.net/wfs" target="_blank">http://www.opengis.net/wfs</a>&quot;<br>
xmlns:xsi=&quot;<a href="http://www.w3.org/2001/XMLSchema-instance" target="_blank">http://www.w3.org/2001/XMLSchema-instance</a>&quot; service=&quot;WFS&quot;<br>
version=&quot;1.0.0&quot; xsi:schemaLocation=&quot;<a href="http://www.opengis.net/wfs" target="_blank">http://www.opengis.net/wfs</a><br>
<a href="http://schemas.opengis.net/wfs/1.0.0/WFS-transaction.xsd" target="_blank">http://schemas.opengis.net/wfs/1.0.0/WFS-transaction.xsd</a><br>
http://*********/tows<br>
http://**********/cgi-bin/tinyows?service=WFS&amp;amp;version=1.0.0&amp;amp;request=DescribeFeatureType&amp;amp;TypeName=france_linie2&quot;&gt;<br>
  &lt;wfs:Insert&gt;<br>
    &lt;feature:france_linie2 xmlns:feature=&quot;http://******/tows&quot;&gt;<br>
      &lt;feature:the_geom&gt;<br>
        &lt;gml:LineString xmlns:gml=&quot;<a href="http://www.opengis.net/gml" target="_blank">http://www.opengis.net/gml</a>&quot;<br>
srsName=&quot;EPSG:27582&quot;&gt;<br>
          &lt;gml:coordinates decimal=&quot;.&quot; cs=&quot;,&quot;<br>
ts=&quot; &quot;&gt;671270.13157895,2322786.3289474<br>
685178.15789474,1942633.6096491&lt;/gml:coordinates&gt;<br>
        &lt;/gml:LineString&gt;<br>
      &lt;/feature:the_geom&gt;<br>
    &lt;/feature:france_linie2&gt;<br>
  &lt;/wfs:Insert&gt;<br>
&lt;/wfs:Transaction&gt;<br>
<br>
RESPONSE:<br>
<br>
&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot;?&gt;<br>
&lt;wfs:WFS_TransactionResponse version=&quot;1.0.0&quot;<br>
 xmlns:wfs=&quot;<a href="http://www.opengis.net/wfs" target="_blank">http://www.opengis.net/wfs</a>&quot;<br>
 xmlns:xsi=&quot;<a href="http://www.w3.org/2001/XMLSchema-instance" target="_blank">http://www.w3.org/2001/XMLSchema-instance</a>&quot;<br>
 xmlns:ogc=&quot;<a href="http://www.opengis.net/ogc" target="_blank">http://www.opengis.net/ogc</a>&quot;<br>
 xsi:schemaLocation=&#39;<a href="http://www.opengis.net/wfs" target="_blank">http://www.opengis.net/wfs</a><br>
<a href="http://schemas.opengis.net/wfs/1.0.0/WFS-transaction.xsd" target="_blank">http://schemas.opengis.net/wfs/1.0.0/WFS-transaction.xsd</a>&#39;&gt;<br>
&lt;wfs:InsertResult handle=&quot;TinyOWS-WFS-default-handle&quot;&gt;&lt;ogc:FeatureId<br>
fid=&quot;france_linie2.80&quot;/&gt;&lt;/wfs:InsertResult&gt;<br>
&lt;wfs:TransactionResult&gt;<br>
&lt;wfs:Status&gt;&lt;wfs:SUCCESS/&gt;&lt;/wfs:Status&gt;<br>
&lt;/wfs:TransactionResult&gt;<br>
&lt;/wfs:WFS_TransactionResponse&gt;<br>
<br>
_____________________________________________________________<br>
<br>
Alex<br>
<br>
--<br>
Alexander Sch?fer | ++49-541-335083-0 | <a href="http://www.intevation.de/" target="_blank">http://www.intevation.de/</a> |<br>
Intevation GmbH, Neuer Graben 17, 49074 Osnabr?ck | AG Osnabr?ck, HR B 18998<br>
Gesch?ftsf?hrer: Frank Koormann, Bernhard Reiter, Dr. Jan-Oliver Wagner<br>
<br>
<br>
------------------------------<br>
<br>
Message: 5<br>
Date: Thu, 17 Dec 2009 09:55:34 +0100<br>
From: Olivier Courtin &lt;<a href="mailto:olivier.courtin@gmail.com">olivier.courtin@gmail.com</a>&gt;<br>
Subject: Re: [TinyOWS-users] INSERT is not working<br>
To: Alexander Sch?fer &lt;<a href="mailto:alexander.schaefer@intevation.de">alexander.schaefer@intevation.de</a>&gt;<br>
Cc: <a href="mailto:tinyows-users@lists.maptools.org">tinyows-users@lists.maptools.org</a><br>
Message-ID: &lt;<a href="mailto:680967CE-E66B-4C71-8698-C1BD707A79F9@gmail.com">680967CE-E66B-4C71-8698-C1BD707A79F9@gmail.com</a>&gt;<br>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed; delsp=yes<br>
<br>
<br>
On Dec 17, 2009, at 9:34 AM, Alexander Sch?fer wrote:<br>
<br>
Hi Alex<br>
<br>
&gt; I use tinyows 0.7.0/SVN Version (Revision 185) as a WFS Server with<br>
&gt; OpenLayers<br>
&gt; 2.8. The update and delete feature works fine. But it is not<br>
&gt; possible for me<br>
&gt; to save newly drawn features.<br>
<br>
Tks for your (very) detailled report !<br>
I just created a ticket related to this point<br>
&lt;<a href="http://tinyows.org/trac/ticket/42" target="_blank">http://tinyows.org/trac/ticket/42</a>&gt;<br>
<br>
I also think that a short tutorial, to explain howto<br>
deploy TinyOWS with OpenLayers could be nice<br>
<br>
I will have time to look further on this point next week,<br>
<br>
--<br>
Olivier<br>
<br>
<br>
<br>
<br>
------------------------------<br>
<br>
_______________________________________________<br>
TinyOWS-users mailing list<br>
<a href="mailto:TinyOWS-users@lists.maptools.org">TinyOWS-users@lists.maptools.org</a><br>
<a href="http://lists.maptools.org/mailman/listinfo/tinyows-users" target="_blank">http://lists.maptools.org/mailman/listinfo/tinyows-users</a><br>
<br>
<br>
End of TinyOWS-users Digest, Vol 7, Issue 5<br>
*******************************************<br>
</blockquote></div><br><br clear="all"><br>-- <br><br>¯`&#39;•.¸(¯`&#39;•.¸*♥♥♥♥*¸.•&#39;´¯)¸.•&#39; ´¯)<br>♥(¯`&#39;•.¸(¯`&#39;•.¸*♥♥*¸.•&#39;´¯)¸.•&#39; ´¯)♥<br>♥♥(¯`&#39;•.¸(¯`&#39;•.¸**¸.•&#39;´¯)¸.•&#39;´ ¯)♥♥<br>----==--12hsitfaHaftish21--==----<br>
(_¸.•&#39;´(_¸.•&#39;´*♥♥♥♥*`&#39;•.¸_)`&#39;• .¸_)<br>♥(_¸.•&#39;´(_¸.•&#39;´*♥♥*`&#39;•.¸_)`&#39;•. ¸_)♥<br>♥♥(_¸.•&#39;´(_¸.•&#39;´**`&#39;•.¸_)`&#39;•.¸ _)♥♥<br>