[TinyOWS-users] Problem inserting features

Olivier Courtin olivier.courtin at gmail.com
Mon Sep 19 16:53:15 EST 2011

On Mon, Sep 19, 2011 at 10:22 PM, Brian May <bmay at mapwise.com> wrote:
> Getting TinyOWS to work has been a long and winding road - still no success
> - and almost ready to give up. Here's the latest on what I have tried and
> the results.
> I ended up trying it out on linux and got further down the road, but
> different problems. I compiled it from source from SVN. I can insert
> features via QGIS and OpenLayers now, but the inserted features do not have
> any geometry (confirmed via checking out the table in postgres). And I can
> see existing features in QGIS that I manually added via a direct connect to
> postgres, but not in OpenLayers! I have been running down a lot of rabbit
> holes trying to get this figured out, burning a lot of time and I could
> really use some help.

Naive question but do you use a PostGIS version >= 1.5.0 ?

If so i suggest that you follow strictly the existing tutorial,

What happen then ?

Then use a QGIS >= 1.6 as a WFS-T client,
same question what behaviour ?

> Also, I may have found a few bugs in the process. For example, if you have
> two geometry columns in your table, and do not inform tinyows of the
> additional geometry column via the config file, it produces a 500 error when
> testing from the browser.

There's no need (and so no way) to indicate to TinyOWS if a column is a geometry
or not (it used geometry/geography column table/view to do so)

So i'm curious about how you are exactly able to obtain a HTTO 500 error type.

> Does tinyows expect the_geom vs. wkb_geometry?
> Tried both and it seems to operate the same, except when you have them both
> there at the same time.

Humm there's no naming convention if that is the question,
thing meaningfull is the type (geometry or geography so)

> I don't remember if this is in the docs, but you must have a record in the
> geometry_columns table for tinyows to recognize the layer at all - you can
> have your config all set up right, and it just won't show the layer as being
> available.

Indeed it is a basis rule of PostGIS administration:
to keep your geometry data sync to geometry_columns table.

populate_geometry_columns() could help so...

> If you change the geometry column name in your table and the geometry column
> name in the geometry_columns table don't match - doing ./tinyows --check
> produces the following error:
> row number 0 is out of range 0..-1
> tinyows: src/struct/buffer.c:254: buffer_add_str: Assertion `str' failed.
> Aborted

PostGIS 2.0 will avoid this as now geometry_column becoming a View
and forbid the database admistrator to unsync datas and metadatas.

A fix was commited as r615 for previous version.
Should be better now.

> Is there any reason why having your data in 900913 projection would be a
> problem? Wasn't my first choice, but I figured i could eliminate projection
> problems that way since the map is in 900913.

As long as your srid is rightly set in sptail_ref_sys table,
it should not be a specific issue for TinyOWS

Cf Carlos answer,

> Also, not sure why, but after some change I made, the url
> http://myurl/cgi-bin/tinyows?service=WFS&request=DescribeFeatureType&version=1.1.0&
> is producing a much more terse output than before. Haven't figured out what
> it is yet, although if I take out my custom layer, and just have the france
> demo, the verbose output comes back.
> If its easier to help debug this, I can open it up to the outside world
> temporarily.

If you give me enough information to reproduce it,
i can go on, but right not yet the case.


More information about the TinyOWS-users mailing list