Re: [postgis-users] Basic question #3 schemas

2009-02-19 Thread Kevin Neufeld
Ben Madin wrote: thank you very much for this - can I just clarify: When you install a new PostGIS, you install the 'current' postgis into the public schema, but all your data & functions into other schemas; Yes, that's my preference anyway. Upgrading then is simply a task of creating a ne

Re: [postgis-users] Basic question #1 Managing temporality in spatial data - MAUP over time

2009-02-19 Thread Ben Madin
Thanks Paul, I will check out contrib/seg - it sounds like it might have application for another (unrelated) issue I am dealing with. It's a neat solution (as are most of these modules) to a problem. cheers Ben On 20/02/2009, at 5:01 AM, postgis-users- requ...@postgis.refractions.net wr

Re: [postgis-users] Plpgsql function

2009-02-19 Thread alex bodnaru
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 hi eehab, eehab hamzeh wrote: > > Hello, > > I have the following plpgsql function the output are 3 values. i need to > insert these values to the table. > when i run the function, only the first value of the result are inserted > how i can insert t

Re: [postgis-users] Basic question #3 schemas

2009-02-19 Thread Ben Madin
G'day Kevin, thank you very much for this - can I just clarify: When you install a new PostGIS, you install the 'current' postgis into the public schema, but all your data & functions into other schemas; or do you create a schema for postgis (again separate from the public and your other '

[postgis-users] Plpgsql function

2009-02-19 Thread eehab hamzeh
Hello, I have the following plpgsql function the output are 3 values. i need to insert these values to the table. when i run the function, only the first value of the result are inserted how i can insert the rest of the result to the table CREATE OR REPLACE FUNCTION eehab(integer) RETURNS int

Re: [postgis-users] PostGIS functions inside triggers

2009-02-19 Thread Eduin Yezid Carrillo Vega
Thanks Ralf. Both tables have primary keys and GeomFromText definition is fine now. Still getting empty values. Eduin Yesid Carrillo Vega Bogotá D.C., Colombia On Mon, Feb 16, 2009 at 1:40 PM, Ralf Suhr wrote: > Mhm my fault. > > Change one line in the function. > > NEW.the_geom := ST_GeomFrom

Re: [postgis-users] Re: maximum distance between a POINT and POLYGON

2009-02-19 Thread Kevin Neufeld
Try moving your query into a subquery and then taking the max distance. Also, you can probably drop the subquery you put as a parameter to the generate_series call. Why are you converting the geometry to text, then back to a geometry again? ie. SELECT "cellID", max(dist) FROM ( -- Your query

Re: [postgis-users] Import GeoDB into PostGIS?

2009-02-19 Thread Chris Hermansen
ogr2ogr will save you. Abram Gillespie wrote: > Is there a direct way (something akin to shp2pgsql) to import data > from a personal geodatabase? I have an acquaintance whose geodb is so > large that exporting to shp always times out. Was hoping there was a > way to skip the middle step. > > Tha

Re: [postgis-users] Import GeoDB into PostGIS?

2009-02-19 Thread Andreas Albarello
On 19 Feb 2009, at 16:31, Abram Gillespie wrote: Is there a direct way (something akin to shp2pgsql) to import data from a personal geodatabase? I have an acquaintance whose geodb is so large that exporting to shp always times out. Was hoping there was a way to skip the middle step. OGR (ht

RE: [postgis-users] Import GeoDB into PostGIS?

2009-02-19 Thread Obe, Regina
I use OGR2OGR for that. http://www.bostongis.com/PrinterFriendly.aspx?content_name=ogr_cheatshee t There is a section further down on importing personal geo database. I've been successful importing 1 million record table, but have never tried a bigger set so not sure how much you can get away w

Re: [postgis-users] Import GeoDB into PostGIS?

2009-02-19 Thread Bruce Rindahl
ogr2ogr will convert all the features in a GeoDB to SQL commands for PostGIS Bruce Abram Gillespie wrote: Is there a direct way (something akin to shp2pgsql) to import data from a personal geodatabase? I have an acquaintance whose geodb is so large that exporting to shp always times out. Was h

RE: [postgis-users] Re: maximum distance between a POINT and POLYGON

2009-02-19 Thread Obe, Regina
I should add when implemented it would work for all geometries similar to the way ST_Distance does. So think of ST_Distance as ST_Min_Distance From: postgis-users-boun...@postgis.refractions.net [mailto:postgis-users-boun...@postgis.refractions.net] On Behal

[postgis-users] Import GeoDB into PostGIS?

2009-02-19 Thread Abram Gillespie
Is there a direct way (something akin to shp2pgsql) to import data from a personal geodatabase? I have an acquaintance whose geodb is so large that exporting to shp always times out. Was hoping there was a way to skip the middle step. Thanks! -Abe ___

RE: [postgis-users] Re: maximum distance between a POINT and POLYGON

2009-02-19 Thread Obe, Regina
It hasn't been implemented. Well it was a long long time ago, but the logic was incorrect so it was turned off. We plan to bring it back probably in a 1.4.something or 1.5 From: postgis-users-boun...@postgis.refractions.net [mailto:postgis-users-boun...@postgis

Re: [postgis-users] ST_AsSVG crashes with large/complex geometries

2009-02-19 Thread Mark Cave-Ayland
Mike Leahy wrote: Hello list, I'm wondering if anyone has run into issues with st_assvg locking up postgresql. I have an application that generates svg from unioned sets of geometries. So far it has been working pretty well, except I just tested it with very large sets of geometries, and i

Re: [postgis-users] Re: maximum distance between a POINT and POLYGON

2009-02-19 Thread nicklas . aven
Sorry, I guessST_Max_Distance(geometry g1, geometry g2) is just for linestrings in current release but in the doc for 1.4 it is presented with geometry1 and geometry2 /Nicklas 2009-02-19 My Pid wrote: Hello again, > >I found the generate_series function (yes i am a newbie!) and I can use it in

Re: [postgis-users] Re: maximum distance between a POINT and POLYGON

2009-02-19 Thread nicklas . aven
Hallo What is the problem withST_Max_Distance(geometry g1, geometry g2)? /Nicklas 2009-02-19 My Pid wrote: Hello again, > >I found the generate_series function (yes i am a newbie!) and I can use it in >order to calculate the distance between > my centroid (geometry_centroid) and my polygon

AW: [postgis-users] ST_AsSVG crashes with large/complex geometries

2009-02-19 Thread Hugentobler Marco
Hi Mike It would be helpfull if you could send a sample geometry (maybe directly to me in order to not give advice for easy dos attacks). It may not only be the size but also the complexity or the way a geometry is composed. Regards, Marco -Ursprüngliche Nachricht- Von: postgis-users-

[postgis-users] ST_AsSVG crashes with large/complex geometries

2009-02-19 Thread Mike Leahy
Hello list, I'm wondering if anyone has run into issues with st_assvg locking up postgresql. I have an application that generates svg from unioned sets of geometries. So far it has been working pretty well, except I just tested it with very large sets of geometries, and it invariably locks u

[postgis-users] Re: maximum distance between a POINT and POLYGON

2009-02-19 Thread My Pid
Hello again, I found the generate_series function (yes i am a newbie!) and I can use it in order to calculate the distance between my centroid (geometry_centroid) and my polygon (geometry_zone) with the following request SELECT (distance_spheroid(geometry_centroid,ST_AsText(ST_PointN(ExteriorRi

Re: [postgis-users] Merging Contour tables in PostGIS

2009-02-19 Thread Eduin Yezid Carrillo Vega
As general rule, don't use UPPERcase field names (oracle way). If you really need to use them, use double quotes: SELECT a."ELEVATION",ST_LineMerge(ST_Collect(a.the_geom, b.the_geom)) AS the_geom INTO merged_contours FROM contours1 AS a,contours2 AS b GROUP BY "ELEVATION"; Eduin Yesid Carrillo V

RE: [postgis-users] Merging Contour tables in PostGIS

2009-02-19 Thread Paragon Corporation
Max, It looks like when you created your table you created ELEVATION as "ELEVATION". Better to not use quotes when defining fields since PostgreSQL will take the column name literally rather than forcing to lowercase. Which means you have to refer to it as a."ELEVATION" If you don't quote you