[TinyOWS-users] Problem inserting new features
Brian May
bmay at mapwise.com
Fri Sep 9 06:31:59 EST 2011
More testing results:
Tried with the latest MS4W - same results.
Tried editing with QGIS 1.6 - same results.
Implemented the sample data, config file, openlayers code etc. - same
results.
Tried editing sample data in QGIS - same results.
Here's some log information at different levels when using QGIS with the
frida sample data trying to do an insert, i.e. draw new feature and save
it. The action was repeated at different log levels. Its interesting
that no info is reported at log level 1.
Log Level 1
nothing reported
Log level 2
[Fri Sep 09 07:15:03 2011] [EVENT] == TINYOWS STARTUP ==
[Fri Sep 09 07:15:03 2011] [EVENT] == Connection PostGIS ==
[Fri Sep 09 07:15:03 2011] [EVENT] == Filling Storage ==
[Fri Sep 09 07:15:03 2011] [EVENT] == FCGI START ==
Log level 4
[Fri Sep 09 07:24:49 2011] [QUERY] <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://wms1.mapwise.com/
http://wms1.mapwise.com/cgi-bin/tinyows.exe?SERVICE=WFS&VERSION=1.0.0&REQUEST=DescribeFeatureType&TYPENAME=feature:frida"
xmlns:feature="http://wms1.mapwise.com/" ><Insert
xmlns="http://www.opengis.net/wfs"><frida
xmlns="http://wms1.mapwise.com/"><the_geom
xmlns="http://wms1.mapwise.com/"><MultiPolygon
xmlns="http://www.opengis.net/gml" srsName="EPSG:31467" ><polygonMember
xmlns="http://www.opengis.net/gml"><Polygon
xmlns="http://www.opengis.net/gml"><outerBoundaryIs
xmlns="http://www.opengis.net/gml"><LinearRing
xmlns="http://www.opengis.net/gml"><coordinates
xmlns="http://www.opengis.net/gml" cs="," ts=" " >-378170,2.5856e+06
-365174,2.31529e+06 -140343,2.32048e+06 -142942,2.5869e+06
-266404,2.5986e+06
-378170,2.5856e+06</coordinates></LinearRing></outerBoundaryIs></Polygon></polygonMember></MultiPolygon></the_geom></frida></Insert></Transaction>
Log Level 8
[Fri Sep 09 07:28:37 2011] [SQL] SELECT substr(postgis_full_version(),
10, 5)
[Fri Sep 09 07:28:37 2011] [SQL] SELECT DISTINCT f_table_schema,
f_table_name FROM geometry_columns
[Fri Sep 09 07:28:37 2011] [SQL] SELECT DISTINCT f_table_schema,
f_table_name FROM geography_columns
[Fri Sep 09 07:28:37 2011] [SQL] SELECT srid, f_geometry_column FROM
geometry_columns WHERE f_table_schema='public' AND f_table_name='frida'
[Fri Sep 09 07:28:37 2011] [SQL] SELECT * FROM spatial_ref_sys WHERE
srid=31467 AND proj4text like '%%units=m%%'
[Fri Sep 09 07:28:37 2011] [SQL] SELECT a.attname AS field, t.typname AS
type FROM pg_class c, pg_attribute a, pg_type t, pg_namespace n WHERE
n.nspname = 'public' AND c.relname = 'frida' AND c.relnamespace = n.oid
AND a.attnum > 0 AND a.attrelid = c.oid AND a.atttypid = t.oid
[Fri Sep 09 07:28:37 2011] [SQL] SELECT type from geometry_columns where
f_table_schema='public' and f_table_name='frida' and
f_geometry_column='the_geom';
[Fri Sep 09 07:28:37 2011] [SQL] SELECT a.attname AS field FROM pg_class
c, pg_attribute a, pg_type t, pg_namespace n WHERE n.nspname = 'public'
AND c.relname = 'frida' AND c.relnamespace = n.oid AND a.attnum > 0 AND
a.attrelid = c.oid AND a.atttypid = t.oid AND a.attnotnull = 't' AND
a.atthasdef='f'
[Fri Sep 09 07:28:37 2011] [SQL] SELECT c.column_name FROM
information_schema.constraint_column_usage c, pg_namespace n WHERE
n.nspname = 'public' AND c.table_name = 'frida' AND c.constraint_name =
(SELECT c.conname FROM pg_class r, pg_constraint c, pg_namespace n WHERE
r.oid = c.conrelid AND relname = 'frida' AND r.relnamespace = n.oid AND
n.nspname = 'public' AND c.contype = 'p')
[Fri Sep 09 07:28:37 2011] [SQL] SELECT a.attnum FROM pg_class c,
pg_attribute a, pg_type t, pg_namespace n WHERE a.attnum > 0 AND
a.attrelid = c.oid AND a.atttypid = t.oid AND n.nspname='public' AND
c.relname='frida' AND a.attname='gid'
[Fri Sep 09 07:28:37 2011] [SQL] SELECT
pg_get_serial_sequence('public."frida"', 'gid');
[Fri Sep 09 07:28:37 2011] [SQL] BEGIN;
[Fri Sep 09 07:28:37 2011] [SQL] SELECT nextval('public.frida_gid_seq');
[Fri Sep 09 07:28:37 2011] [SQL] SELECT ST_GeomFromGML('<MultiPolygon
xmlns="http://www.opengis.net/gml"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:feature="http://wms1.mapwise.com/"
srsName="EPSG:31467"><polygonMember
xmlns="http://www.opengis.net/gml"><Polygon
xmlns="http://www.opengis.net/gml"><outerBoundaryIs
xmlns="http://www.opengis.net/gml"><LinearRing
xmlns="http://www.opengis.net/gml"><coordinates
xmlns="http://www.opengis.net/gml" cs="," ts=" ">-378170,2.5856e+06
-365174,2.31529e+06 -140343,2.32048e+06 -142942,2.5869e+06
-266404,2.5986e+06
-378170,2.5856e+06</coordinates></LinearRing></outerBoundaryIs></Polygon></polygonMember></MultiPolygon>')
[Fri Sep 09 07:28:37 2011] [SQL] SELECT
ST_IsValid('0106000020EB7A0000010000000103000000010000000600000000000000E81417C10000000000BA434100000000D84916C1000000000DAA414100000000B82101C10000000030B4414100000000F07201C1000000008ABC434100000000904210C10000000064D3434100000000E81417C10000000000BA4341')
Brian
On 9/7/2011 3:57 PM, Brian May wrote:
> 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&request=DescribeFeatureType&version=1.1.0&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
> });
>
>
>
>
> _______________________________________________
> TinyOWS-users mailing list
> TinyOWS-users at lists.maptools.org
> http://lists.maptools.org/mailman/listinfo/tinyows-users
>
More information about the TinyOWS-users
mailing list