<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Tahoma
}
--></style></head>
<body class='hmmessage'><div dir='ltr'>
Could my errors come from the fact that tinyows.exe might be an older version compared to the files (e.g. schema files) found in the latest release (1.0.0rc4).<div>I am using the tinyows.exe that is found in the mapserver site, which I think it's of version 1.0.0rc3.</div><div><br></div><div>If this might be a problem can anyone tell me where to get the tinyows.exe file for the latest version, since I don't know how to compile the source code found in the release? My experience unfortunately is limited to Microsoft technologies (Visual Studio and so on)<br><br><div><div id="SkyDrivePlaceholder"></div><hr id="stopSpelling">From: erndal02@hotmail.com<br>To: tinyows-dev@lists.maptools.org<br>Subject: RE: [TinyOWS-dev] Error when inserting new feature with TinyOWS<br>Date: Fri, 11 May 2012 19:21:55 +0200<br><br>

<style><!--
.ExternalClass .ecxhmmessage P
{padding:0px;}
.ExternalClass body.ecxhmmessage
{font-size:10pt;font-family:Tahoma;}

--></style>
<div dir="ltr">
OK, maybe I should start from the beginning in the desperate need for some help, because I don't think it should be such a difficult situation for the experts. I'm not going to mention my failed attempts with OpenLayers, just with QGis and MS4W and TinyOWS<br><br>I have created one table in the database (schema: public) named olivestwo. This table has only two columns named fid (primary key, serial) and another one named geometry (geometry, type: POLYGON, srid: 32634). I have copied the XSD schema and everything else from the last release of TinyOWS. I have configured the config.xml like this:<br><br><font style="" face="Courier New">&lt;tinyows online_resource="http://127.0.0.1:81/cgi-bin/tinyows.exe"</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">&nbsp; schema_dir="C:/ms4w/apps/tinyows/schema/"</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">&nbsp; check_schema="0"</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; log="C:/ms4w/apps/tinyows/tinyows.log"</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; log_level="15"&gt;</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">&nbsp; &lt;pg host="127.0.0.1" user="postgres" password="olives001" dbname="olives_gis1" port="5432"/&gt;</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">&nbsp; &lt;metadata name="Olives WFST Server"</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; title="WFST Olives" /&gt;</font><font style="" face="Courier New"><br></font><font style="" face="Courier New"><br></font><font style="" face="Courier New">&nbsp; &lt;layer retrievable="1"</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; writable="1"</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ns_prefix="tows"</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ns_uri="http://127.0.0.1:81/"</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; name="olivestwo"</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;schema="public"</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; title="olives test test"/&gt;</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">&lt;/tinyows&gt;</font><font style="" face="Courier New"><br></font><br><br>I have configured the httpd_tinyows.conf within httpd.d folder, like this:<br><br>SetEnv TINYOWS_CONFIG_FILE "C:/ms4w/apps/tinyows/config.xml"<br>SetEnv TINYOWS_SCHEMA_DIR "C:/ms4w/apps/tinyows/schema/"<br><br>&lt;Directory "C:/ms4w/apps/tinyows/"&gt;<br>&nbsp; AllowOverride None<br>&nbsp; Options Indexes FollowSymLinks Multiviews <br>&nbsp; Order allow,deny<br>&nbsp; Allow from all<br>&lt;/Directory&gt;<br><br>The editing and deleting of existing features works very well.<br><br>If I try with this configuration, to insert a new feature from QGis, I get this from the log file:<br><br><font style="" face="Courier New">[QUERY] &lt;Transaction xmlns="http://www.opengis.net/wfs" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.0.0" service="WFS" xsi:schemaLocation="http://127.0.0.1:81/ http://127.0.0.1:81/cgi-bin/tinyows.exe?SERVICE=WFS&amp;amp;VERSION=1.0.0&amp;amp;REQUEST=DescribeFeatureType&amp;amp;TYPENAME=tows:olivestwo&amp;amp;SRSNAME=EPSG:32634" xmlns:tows="http://127.0.0.1:81/"&gt;&lt;Insert xmlns="http://www.opengis.net/wfs"&gt;&lt;olivestwo xmlns="http://127.0.0.1:81/"&gt;&lt;geometry xmlns="http://127.0.0.1:81/"&gt;&lt;Polygon xmlns="http://www.opengis.net/gml" srsName="EPSG:32634"&gt;&lt;outerBoundaryIs xmlns="http://www.opengis.net/gml"&gt;&lt;LinearRing xmlns="http://www.opengis.net/gml"&gt;&lt;coordinates xmlns="http://www.opengis.net/gml" cs="," ts=" "&gt;379105.5268,4513275.2700 378342.3352,4513020.8728 378342.3352,4513020.8728 378342.3352,4513020.8728 378482.2536,4512448.4791 378482.2536,4512448.4791 379041.9275,4512677.4366 379105.5268,4513275.2700&lt;/coordinates&gt;&lt;/LinearRing&gt;&lt;/outerBoundaryIs&gt;&lt;/Polygon&gt;&lt;/geometry&gt;&lt;/olivestwo&gt;&lt;/Insert&gt;&lt;/Transaction&gt;</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">[SQL] BEGIN;</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">[SQL] SELECT nextval('public.olives2_fid_seq');</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">[SQL] SELECT ST_GeomFromGML('&lt;Polygon xmlns="http://www.opengis.net/gml" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:tows="http://127.0.0.1:81/" srsName="EPSG:32634"&gt;&lt;outerBoundaryIs xmlns="http://www.opengis.net/gml"&gt;&lt;LinearRing xmlns="http://www.opengis.net/gml"&gt;&lt;coordinates xmlns="http://www.opengis.net/gml" cs="," ts=" "&gt;379105.5268,4513275.2700 378342.3352,4513020.8728 378342.3352,4513020.8728 378342.3352,4513020.8728 378482.2536,4512448.4791 378482.2536,4512448.4791 379041.9275,4512677.4366 379105.5268,4513275.2700&lt;/coordinates&gt;&lt;/LinearRing&gt;&lt;/outerBoundaryIs&gt;&lt;/Polygon&gt;')</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">[SQL] SELECT ST_IsValid('01030000207A7F000001000000080000008E75711B8623174114AE47D17E37514136AB3E579917174188F4DB373F37514136AB3E579917174188F4DB373F37514136AB3E579917174188F4DB373F375141E9B7AF03C91917410C93A91EB0365141E9B7AF03C91917410C93A91EB03651415C8FC2B5872217412041F15BE93651418E75711B8623174114AE47D17E375141')</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">[SQL] </font><font style="" face="Courier New"><br></font><font style="" face="Courier New">[SQL] ROLLBACK;</font><br><br>If I try to run the ST_IsValid function from PostGIS, it returns 't', meaning that the geometry validates OK.<br>The transaction query seems to be well formed (at least from what I can see).<br><br>If in the config file I try to change the check_schema to "1", I get the following info from the log file:<br><br><font style="" face="Courier New">[EVENT] == FCGI START ==</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">[QUERY] &lt;Transaction xmlns="http://www.opengis.net/wfs" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.0.0" service="WFS" xsi:schemaLocation="http://127.0.0.1:81/ http://127.0.0.1:81/cgi-bin/tinyows.exe?SERVICE=WFS&amp;amp;VERSION=1.0.0&amp;amp;REQUEST=DescribeFeatureType&amp;amp;TYPENAME=tows:olivestwo&amp;amp;SRSNAME=EPSG:32634" xmlns:tows="http://127.0.0.1:81/"&gt;&lt;Insert xmlns="http://www.opengis.net/wfs"&gt;&lt;olivestwo xmlns="http://127.0.0.1:81/"&gt;&lt;geometry xmlns="http://127.0.0.1:81/"&gt;&lt;Polygon xmlns="http://www.opengis.net/gml" srsName="EPSG:32634"&gt;&lt;outerBoundaryIs xmlns="http://www.opengis.net/gml"&gt;&lt;LinearRing xmlns="http://www.opengis.net/gml"&gt;&lt;coordinates xmlns="http://www.opengis.net/gml" cs="," ts=" "&gt;375264.1291,4513249.8303 375391.3277,4512753.7557 376052.7604,4513364.3090 375264.1291,4513249.8303&lt;/coordinates&gt;&lt;/LinearRing&gt;&lt;/outerBoundaryIs&gt;&lt;/Polygon&gt;&lt;/geometry&gt;&lt;/olivestwo&gt;&lt;/Insert&gt;&lt;/Transaction&gt;</font><font style="" face="Courier New"><br></font><font style="" face="Courier New">[ERROR] Element '{http://www.w3.org/2001/XMLSchema}import': Failed to locate a schema at location 'http://127.0.0.1:81/cgi-bin/tinyows.exe?service=WFS&amp;request=DescribeFeatureType&amp;version=1.0.0'. Skipping the import.</font><font style="" face="Courier New"><br></font><font style="" face="Courier New"><br></font><font style="" face="Courier New">[ERROR] Element '{http://127.0.0.1:81/}olivestwo': This element is not expected. Expected is one of ( {http://www.opengis.net/gml}_Feature, {http://www.opengis.net/wfs}FeatureCollection ).</font><font style="" face="Courier New"><br></font><font style="" face="Courier New"><br></font><font style="" face="Courier New">[ERROR] XML request isn't valid</font><font style="" face="Courier New"><br></font><br><br>I have made several tries with different layers, even with the ones from the release and I always have had the same results. I have also changed the ns_uri in config.xml to http://tinyows.org/ and still the same results...<br><br>Can anyone tell me if I am doing something wrong? Has anyone made it work with the MS4W in Windows?<br><br><br>                                               </div></div></div>                                               </div></body>
</html>