Re: [postgis-users] shp2pgsql 1.5 is crashing

2010-10-18 Thread Sebastian E. Ovide
Is there any reason why not to use gdal ogr2ogr ?

On Thu, Oct 14, 2010 at 7:03 PM, Stephen Woodbridge wood...@swoodbridge.com
 wrote:

 On 10/14/2010 12:02 PM, Mark Cave-Ayland wrote:

 Stephen Woodbridge wrote:

  Hi all,

 I'm running into a crashing problem with shp2pgsql on 1.5 release on a
 CentOS 5

 This crashes:
 shp2pgsql -s 4326 -c -D Hydrants_4326.shp data.hydrants

 This works ok:
 shp2pgsql -s 4326 -c -D -N skip Hydrants_4326.shp data.hydrants

 File loads ok in OpenEV and runs through ogr2ogr without a problem.

 -Steve W


 Hi Steve,

 If you're not already running 1.5.2, I'd try that as I seem to remember
 there were a couple of bugfixes that might be relevant here.


 Hi Mark,

 I sort of thought there might have been some fixes, but could not verify
 that and did not realize I was back a version.

 Thanks,
  -Steve

 ___
 postgis-users mailing list
 postgis-users@postgis.refractions.net
 http://postgis.refractions.net/mailman/listinfo/postgis-users




-- 
Sebastian E. Ovide
___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


[postgis-users] AddGeometryColumn BOX3D

2010-10-18 Thread Jan Saalbach

Hi all,
what is the geometry type to chose when storing BOX3D type geometries? 
Of what type does the column need to be? I mean how do I phrase this 
correctly?


---
postgisdb=# SELECT AddGeometryColumn('boxes','box3d',31467,'BOX',3);

FEHLER:  Invalid type name - valid ones are:
POINT, MULTIPOINT,
LINESTRING, MULTILINESTRING,
POLYGON, MULTIPOLYGON,
CIRCULARSTRING, COMPOUNDCURVE, MULTICURVE,
CURVEPOLYGON, MULTISURFACE,
GEOMETRY, GEOMETRYCOLLECTION,
POINTM, MULTIPOINTM,
LINESTRINGM, MULTILINESTRINGM,
POLYGONM, MULTIPOLYGONM,
CIRCULARSTRINGM, COMPOUNDCURVEM, MULTICURVEM
CURVEPOLYGONM, MULTISURFACEM,
or GEOMETRYCOLLECTIONM
---

The reason I need to do this is I would like to use the -operator on 2 
boxes. And comparing the boxes from point3d-sets directly gives me a 
not enough memory error.


Regards,
Jan
___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


Re: [postgis-users] AddGeometryColumn BOX3D

2010-10-18 Thread Mike Toews
Hi Jan,

box3d is not a geometry, but it is it's very own type (along with box2d). If
you have pgAdminIII, you can browse these types (you may need to enable
visibility of types in the options), or if you use psql then the command
\dT will show all types.

Since it isn't a geometry, you can directly create it, e.g.:

create table foo(
  id serial primary key,
  box box3d
);

insert into foo(box) values('BOX3D(0 0 0, 10 10 10)'::box3d);

-Mike

On 18 October 2010 02:34, Jan Saalbach f...@dubmosphere.de wrote:

 Hi all,
 what is the geometry type to chose when storing BOX3D type geometries? Of
 what type does the column need to be? I mean how do I phrase this correctly?

 ---
 postgisdb=# SELECT AddGeometryColumn('boxes','box3d',31467,'BOX',3);

 FEHLER:  Invalid type name - valid ones are:
POINT, MULTIPOINT,
LINESTRING, MULTILINESTRING,
POLYGON, MULTIPOLYGON,
CIRCULARSTRING, COMPOUNDCURVE, MULTICURVE,
CURVEPOLYGON, MULTISURFACE,
GEOMETRY, GEOMETRYCOLLECTION,
POINTM, MULTIPOINTM,
LINESTRINGM, MULTILINESTRINGM,
POLYGONM, MULTIPOLYGONM,
CIRCULARSTRINGM, COMPOUNDCURVEM, MULTICURVEM
CURVEPOLYGONM, MULTISURFACEM,
or GEOMETRYCOLLECTIONM
 ---

 The reason I need to do this is I would like to use the -operator on 2
 boxes. And comparing the boxes from point3d-sets directly gives me a not
 enough memory error.

 Regards,
 Jan
 ___
 postgis-users mailing list
 postgis-users@postgis.refractions.net
 http://postgis.refractions.net/mailman/listinfo/postgis-users

___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


[postgis-users] Simple PostgreSQL versioning

2010-10-18 Thread Ivan Mincik
Dear PostGIS users,
I have created set of database functions for managing editing history
of my PostgreSQL tables, including PostGIS geometry tables. Currently
it is in state of 'proof of concept', but usable. I would like to
share it and get some feedback. I was inspired by versioning functions
of Horst Duester and Andreas Neumann, but implemented in other way.

If You are interested, please download here:
http://gista.sk/home/ivo/projects/simple_pg_versioning/simple_pg_versioning-0.1~r18.tar.gz
Package is containing some README instructions and it is tested only
on my Debian Lenny computers (PostgreSQL 8.3, PostGIS 1.3.3).

How does it work?
1. After loading functions to Your DB, master history table is created
in 'sv_history' schema for every versioning enabled tables.
2. You can enable versioning using  'SV_CreateHistory('schema',
'table')' function (run SELECT SV_CreateHistory('schema',
'table');)
3. Edit Your table 
4. For retrieving table's state in particulal time use
'schema.table_AtTime('timestamp')' function. (run SELECT * FROM
schema.table_AtTime('timestamp');)

So, in case of table called 'mytable' in schema 'gis':
1. Enable versioning:  SELECT SV_CreateHistory('gis', 'mytable');
2. Get the table's state from today's morning: SELECT * FROM
gis.mytable_AtTime('2010-10-18 08:00:00');

I am not database programmer and I lack lot of PL/PgSQL skils,
therefore I used my preferred PL/Python language to solve my ideas.
Any improvements, suggestions, criticism is welcome.

Ivan
___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users