[TinyOWS-users] Problem inserting new features

Brian May bmay at mapwise.com
Wed Sep 7 14:57:07 EST 2011


Hi All,

I am having trouble inserting new features. Read, modify and delete 
transactions work. Insert does not and crashes tinyows.exe. The 
following is my environment and other information that hopefully helps 
find the problem.

Thanks in advance for any help!

Brian May
MapWise Inc.

-------

MS4W version 3 Beta 11
Windows Vista

---------------------------------------------------------------------
OpenLayers POST
---------------------------------------------------------------------
<wfs:Transaction xmlns:wfs="http://www.opengis.net/wfs" service="WFS" 
version="1.1.0" xsi:schemaLocation="http://www.opengis.net/wfs 
http://schemas.opengis.net/wfs/1.1.0/wfs.xsd http://localhost 
http://localhost/cgi-bin/tinyows.exe?service=wfs&amp;request=DescribeFeatureType&amp;version=1.1.0&amp;typename=bs:custom_lines" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><wfs:Insert><feature:custom_lines 
xmlns:feature="http://localhost"><feature:wkb_geometry><gml:MultiCurve 
xmlns:gml="http://www.opengis.net/gml" 
srsName="EPSG:900913"><gml:curveMember><gml:LineString><gml:posList>-8937665.8645125 
3133312.7884098 -8969157.9201616 3111910.420493 -8901587.587167002 
3098763.2516298 -8895778.373018004 
3132395.5440705</gml:posList></gml:LineString></gml:curveMember></gml:MultiCurve></feature:wkb_geometry></feature:custom_lines></wfs:Insert></wfs:Transaction>

---------------------------------------------------------------------
Postgres log
---------------------------------------------------------------------
2011-09-06 23:02:20 EDTLOG:  could not receive data from client: Unknown 
winsock error 10061
2011-09-06 23:02:20 EDTLOG:  unexpected EOF on client connection

---------------------------------------------------------------------
Apache error log
---------------------------------------------------------------------
[Mon Sep 06 23:02:20 2011] [error] [client 192.168.2.143] Premature end 
of script headers: tinyows.exe, referer: http://localhost/

---------------------------------------------------------------------
tinyows.exe --check
---------------------------------------------------------------------
C:\ms4w\Apache\cgi-bin>tinyows.exe --check
TinyOWS version:   1.0.0rc3
FCGI support:      Yes
Config File Path:  c:/ms4w/apps/tinyows/config.xml (TinyOWS XML)
PostGIS Version:   1.5.2
PostGIS dsn:       host=localhost user=xx password=xx dbname=xx port=5432
Output Encoding:   UTF-8
Database Encoding: UTF8
Schema dir:        c:/ms4w/apps/tinyows/schema/
Log file:          c:/ms4w/Apache/logs/tinyows.log
Log level:         SQL
Display bbox:      Yes
Estimated extent:  Yes
Check schema:      No
Check valid geoms: Yes
Available layers:
  - public.custom_lines (900913) -> bs.custom_lines [RW]

---------------------------------------------------------------------
config.xml
---------------------------------------------------------------------
<tinyows online_resource="http://localhost/cgi-bin/tinyows.exe"
     schema_dir="c:/ms4w/apps/tinyows/schema/"
     log="c:/ms4w/Apache/logs/tinyows.log"
     log_level="8"
     display_bbox="1"
     estimated_extent="1"
     check_schema="0">

<pg host="localhost" user="xx" password="xx" dbname="xx" port="5432" />

<metadata name="TinyOWS Server" title="TinyOWS Server - Demo Service" />

<limits features="100" />


<layer retrievable="1"
          writable="1"
          ns_prefix="bs"
          ns_uri="http://localhost"
          name="custom_lines"
          title="Custom Lines TEST"
          />

</tinyows>

---------------------------------------------------------------------
OpenLayers Code
---------------------------------------------------------------------
     saveStrategyLines = new OpenLayers.Strategy.Save();
     wfsCustomLines = new OpenLayers.Layer.Vector(
         "Custom Lines TEST", {
         strategies: [new OpenLayers.Strategy.BBOX(), saveStrategyLines],
         projection: new OpenLayers.Projection("EPSG:900913"), // 
projection of the data - wfs 1.1.0 supports server-side projection
         protocol: new OpenLayers.Protocol.WFS({
             url: "http://localhost/cgi-bin/tinyows.exe",
             featurePrefix: "bs",
             featureType: "custom_lines",
             featureNS: "http://localhost",
             version: "1.1.0",
             srsName: "EPSG:900913", // output projection
             geometryName: "wkb_geometry",
             schema: 
"http://localhost/cgi-bin/tinyows.exe?service=wfs&request=DescribeFeatureType&version=1.1.0&typename=bs:custom_lines"
         }),
         visibility: false
     });






More information about the TinyOWS-users mailing list