Re: [postgis-users] Creating a simple polygon encompassing a given number of points

2012-09-12 Thread René Fournier
2012-09-12, at 10:04 AM, Nicolas Ribot wrote: > Hi, > > I think you could cast geography to geometry to collect, then cast > back to geography to store ? > > > > On 12 September 2012 17:42, René Fournier wrote: >> Yes, this works great. >> >> UPDATE te

Re: [postgis-users] Creating a simple polygon encompassing a given number of points

2012-09-12 Thread René Fournier
used geometry types? Sorry for the dumb questions, I'm trying to define the schemas by best practices so I don't have to fix them later. Geography seemed right when I started the project. On 2012-09-11, at 1:18 AM, Paolo Corti wrote: > On Tue, Sep 11, 2012 at 3:44 AM, René F

Re: [postgis-users] Creating a simple polygon encompassing a given number of points

2012-09-10 Thread René Fournier
l may give you better results on polygon approximation > (see: > http://postgis.refractions.net/documentation/manual-2.0/ST_ConcaveHull.html) > > Nicolas > > On 10 September 2012 20:39, René Fournier wrote: >> I've written a script to migrate location data from MySQ

[postgis-users] Creating a simple polygon encompassing a given number of points

2012-09-10 Thread René Fournier
I've written a script to migrate location data from MySQL to PostGIS. Each region contains 5-20 locations. I would like my script to create a simple polygon for each region that encompasses its locations (lat/lng points). I say simple in the sense of not too many vertices (< 10), even if the regi

Re: [postgis-users] Super weird problem: Cannot insert more than ~300 rows (or ~100 kb) into a table

2012-07-12 Thread René Fournier
, &b); >>> >>> >>> On Tue, Jul 10, 2012 at 9:50 AM, Paul Ramsey wrote: >>>> Since others get crashes on 1.5.4, I tested *exactly* that version and >>>> lo, it does in fact crash. The current 1.5 stable branch does not >>>> cr

Re: [postgis-users] Super weird problem: Cannot insert more than ~300 rows (or ~100 kb) into a table

2012-07-10 Thread René Fournier
quot;boom" and then create a > ticket on the tracker with the dump file attached. > > http://trac.osgeo.org/ > > Thanks! > > P. > > On Wed, Jul 4, 2012 at 2:01 AM, René Fournier wrote: >> I've narrowed the point at which a crash will always ha

Re: [postgis-users] Super weird problem: Cannot insert more than ~300 rows (or ~100 kb) into a table

2012-07-06 Thread René Fournier
atever) > rows, confirm that the file makes things go "boom" and then create a > ticket on the tracker with the dump file attached. > > http://trac.osgeo.org/ > > Thanks! > > P. > > On Wed, Jul 4, 2012 at 2:01 AM, René Fournier wrote: >> I've nar

Re: [postgis-users] Super weird problem: Cannot insert more than ~300 rows (or ~100 kb) into a table

2012-07-04 Thread René Fournier
last completed transaction was at log time 2012-07-04 10:44:40.712517+02 LOG: database system is ready to accept connections On 2012-07-03, at 6:31 PM, Mark Cave-Ayland wrote: > On 03/07/12 13:20, René Fournier wrote: > >> So, it seems that the table gets full and corrupted to some

Re: [postgis-users] Super weird problem: Cannot insert more than ~300 rows (or ~100 kb) into a table

2012-07-03 Thread René Fournier
- 50 (1 row) INSERT 0 1 mydb=# So, it appears there's some weird corruption going on... Still, not sure what to try next. My PostGIS is via Macports, not sure how to enable the debug mode... On 2012-07-03, at 2:03 PM, René Fournier wrote: > On 2012-07-03, at 1:43 PM, Mark Cave-Ayl

Re: [postgis-users] Super weird problem: Cannot insert more than ~300 rows (or ~100 kb) into a table

2012-07-03 Thread René Fournier
On 2012-07-03, at 1:43 PM, Mark Cave-Ayland wrote: > On 03/07/12 12:34, René Fournier wrote: > >> >> If I quit and restart psql, same error occurs. Only if I drop the table >> can I insert more rows — but again, only up to around 300 rows or 100 kb >> (not sure w

Re: [postgis-users] Super weird problem: Cannot insert more than ~300 rows (or ~100 kb) into a table

2012-07-03 Thread René Fournier
on the kind of coordinates or row data, just the number of inserts and/or the amount of data. Any ideas what is causing the problem here? On 2012-07-02, at 1:22 PM, Sandro Santilli wrote: > Please file a ticket, and report the output of postgis_full_version() > > --strk; > >

[postgis-users] Super weird problem: ST_GeomFromText('POINT(-114.112534 50.895364)') works, ST_GeomFromText('POINT(-114.228869 51.152249)') fails -- why?

2012-07-02 Thread René Fournier
If I try to insert a row containing particular coordinate, the query fails and the DB connection is lost. (By comparison, hundreds of inserts of other coordinates work fine.) Here's a straight copy-and-paste comparison from psql: mydb=# INSERT INTO addresses ( account_id, territory_id, location

[postgis-users] Good Mac app for editing Shape (.shp) files?

2011-11-28 Thread René Fournier
I've noticed some irregularities/mistakes in certain polygons describing state borders in a shape file I downloaded. I would like to correct the mistakes — basically remove some of the points along certain line segments, and move the position of other lines — then re-import into Postgresql. Can

Re: [postgis-users] Problems with backing up and restoring Tiger Geocoder database

2011-11-10 Thread René Fournier
gt;> (you want -F c -b >> >> pg_restore can only be used to restore tar or compressed backups. >> >> We restore the tiger data all the time to various servers so >> no issue there. >> >> >> Leo and Regina >> http://www.postgis.us >>

Re: [postgis-users] Problems with backing up and restoring Tiger Geocoder database

2011-11-09 Thread René Fournier
> Leo and Regina > http://www.postgis.us > > > >> -Original Message- >> From: postgis-users-boun...@postgis.refractions.net >> [mailto:postgis-users-boun...@postgis.refractions.net] On >> Behalf Of René Fournier >> Sent: Wednesday, No

[postgis-users] Problems with backing up and restoring Tiger Geocoder database

2011-11-09 Thread René Fournier
Since building the Tiger Geocoder database from the source data is so time-consuming, I'm trying to capture the result (the ~90GB spatially aware database) so that I can simply restore, in case I need to rebuild the server. Should be simple, but every time I pg_dump and attempt to pg_restore, I

[postgis-users] Tuning PostgreSQL for a very large database

2011-11-06 Thread René Fournier
Just wondering what I can do to squeeze out more performance of my database application? Here's my configuration: - Mac mini server - Core i7 quad-core at 2GHz - 16GB memory - Dedicated fast SSD (two SSDs in the server) - Mac OS X 10.7.2 (*not* using OS X Server) - PostgreSQL 9.05 - PostGIS 1.5.3

[postgis-users] Tuning PostgreSQL for very large database

2011-11-06 Thread René Fournier
Just wondering what I can do to squeeze out more performance of my database application? Here's my configuration: - Mac mini server - Core i7 quad-core at 2GHz - 16GB memory - Dedicated fast SSD (two SSDs in the server) - Mac OS X 10.7.2 (*not* using OS X Server) - PostgreSQL 9.05 - PostGIS 1.5.3

[postgis-users] PostGIS 1.5.3 and Tiger Geocoder after restore

2011-10-26 Thread René Fournier
I had the Tiger Geocoder 2010 working great on one machine. I dumped the database to a file, and then restored it to a fresh Postgresql90 + PostGIS 1.5.3 (a la Macports)… via psql -U postgres -q -d gc4 -f tiger_dump.sql But there were a few notices/errors on the import: psql:/Volumes/Extra/GC/U

[postgis-users] Problem installing PostgreSQL 9.0 via Macports on OS X Server 10.6

2011-10-23 Thread René Fournier
[…] ---> Installing postgresql90-server @9.0.5_0 To create a database instance, after install do sudo mkdir -p /opt/local/var/db/postgresql90/defaultdb sudo chown postgres:postgres /opt/local/var/db/postgresql90/defaultdb sudo su postgres -c '/op

Re: [postgis-users] Tiger Geocoder: SELECT loader_generate_script( --all states -- , 'sh') ??

2011-10-20 Thread René Fournier
Thanks Regina! On 2011-10-20, at 6:04 PM, Paragon Corporation wrote: > […] > As far as short-hand for all states. You could do > > SELECT loader_generate_script(ARRAY(SELECT abbrev FROM state_lookup ORDER BY > abbrev), 'windows'); > > That still isn't perfect since you get duplicate path sett

[postgis-users] Tiger Geocoder: SELECT loader_generate_script( -- all states -- , 'sh') ??

2011-10-20 Thread René Fournier
This: SELECT loader_generate_script(ARRAY['DC','RI'], 'windows'); …returns a shell script that will wget the Tiger data for the states of DC and Rhode Island. And, aside from a couple small bugs, works very well. I was wondering if there were a shorthand for generating a shell script th

[postgis-users] Using Tiger Geocoder -- Shapefile for US cities

2011-10-18 Thread René Fournier
I stumbled across this guide for installing the Tiger Geocoder (PostGIS 2.0): http://www.letseehere.com/postgis-geocoder-using-tiger-2010-data Anyone else walk through the guide? Comments? Also, I could solve my current problem (reverse-geocoding works, but I don't get the city/town) by

Re: [postgis-users] Tiger Line 2010 - Edges

2011-10-18 Thread René Fournier
e data of the TIGER FACE layers (the > topological faces), you can then determine the "place" > (city, town, or Census Designated place) FIPS code associated with the > topological face that is bounded by a road edge. To get the name of the > "place", you then ne

[postgis-users] Tiger Line 2010 - Edges

2011-10-18 Thread René Fournier
Having imported the Edges shape files, I'm able to get quickly find the closest street to a given latlng point (reverse-geocode). From this row, I get the street name and house number ranges, and state (FIPS code) -- but not the city name. Any suggestions on the best way to find the town/city?

Re: [postgis-users] Finding the closest house number on a street

2011-10-16 Thread René Fournier
Sorry, I wrote too soon. This function appears to be for forward-geocoding (address -> latlng) not reverse. On 2011-10-14, at 3:02 AM, Paragon Corporation wrote: > Also you may want to take a look at the tiger helper function -- > > http://trac.osgeo.org/postgis/browser/trunk/extras/tiger_geo

Re: [postgis-users] Finding the closest house number on a street

2011-10-16 Thread René Fournier
r > > but most people using it in production are using it with PostGIS 1.5 and > works fine with that. > > Hope that helps, > Regina > http://www.postgis.us > > > From: postgis-users-boun...@postgis.refractions.net > [mailto:postgis-users-boun...@postgis.refractions

Re: [postgis-users] Finding the closest house number on a street

2011-10-13 Thread René Fournier
089798 43.81621783)'::box3d,4326) ORDER BY distance ASC LIMIT 1; ERROR: line_locate_point: 1st arg isnt a line gc3=# So I'm using PostGIS 1.5.3, and the docs (http://postgis.refractions.net/docs/ST_Line_Locate_Point.html) say that multilinestrings are supported, so…. ??? On 2011-10

[postgis-users] Finding the closest house number on a street

2011-10-13 Thread René Fournier
In PostGIS parlance, given a lat/lng point... where -- in terms of percentage or decimal -- does it lie along on a row's multilinestring? The thing is, the multilinestring is just a single line string. But I suppose there are cases where there are more than one segment to the street… In any ca