[GRASS-user] V.in.ogr error processing shape file from GEOBASE. Anyother experieinces?

Sampson, David dsampson at NRCan.gc.ca
Fri Aug 11 08:32:04 EDT 2006


Hmmmm... I might have made a mistake saying that it failed on 6.1, cause I re-did it yesterday and it appears as though it loaded fine so far...

Maybe it was a bug in 6.0.2

I also took the dataset and did an ogr2ogr and gave it a proper projection based off of the metadata I think I gave it EPSG:4269. Perhaps this translation affected something.

Thanks for testing it out... I will try to reproduce the v.vb.select 

cheers

-----Original Message-----
From: Aaron Racicot [mailto:aaronr at ecotrust.org] 
Sent: August 10, 2006 16:48
To: Sampson, David; grassuser at grass.itc.it
Subject: RE: [GRASS-user] V.in.ogr error processing shape file from GEOBASE. Anyother experieinces?

Hi there David,
I downloaded the file and looked at it with 'ogrinfo -al' and it read the file fine.  I then imported it into a grass location:

GRASS 6.1.cvs (canada_roads):~/work/tmp > v.in.ogr dsn=ROADSEG.shp output=roadseg_grass
WARNING: Datum 'NAD83_Canadian_Spatial_Reference_System' not recognised by
         GRASS and no parameters found. Datum transformation will not be
         possible using this projection information.
Projection of input dataset and current location appear to match.
Proceeding with import...
Layer: ROADSEG
-----------------------------------------------------
Building topology ...
467138 primitives registered
Building areas:  100%
0 areas built
0 isles built
Attaching islands:
Attaching centroids:  100%
Topology was built.
Number of nodes     :   342698
Number of primitives:   467138
Number of points    :   0
Number of lines     :   467138
Number of boundaries:   0
Number of centroids :   0
Number of areas     :   0
Number of isles     :   0
GRASS 6.1.cvs (canada_roads):~/work/tmp >

All good so far (except the datum issue).  Next I did a v.db.select roadseg_grass and got:

...
48390|f1635c9fd238431abae8af61d795c00f|Ontario|National Road Network - 
48390|f1635c9fd238431abae8af61d795c00f|Ontario|Réseau Routier National 
48390|f1635c9fd238431abae8af61d795c00f|Ontario|V1.0|3|Digital 
48390|f1635c9fd238431abae8af61d795c00f|Ontario|Data|Provincial|2002/05|E
48390|f1635c9fd238431abae8af61d795c00f|Ontario|xpressway / 
48390|f1635c9fd238431abae8af61d795c00f|Ontario|Highway|9|None|None|None|
48390|f1635c9fd238431abae8af61d795c00f|Ontario|None|None|None|None|None|
48390|f1635c9fd238431abae8af61d795c00f|Ontario|None|None|None|None|None|
48390|f1635c9fd238431abae8af61d795c00f|Ontario|3|Paved 
48390|f1635c9fd238431abae8af61d795c00f|Ontario|Surface|Unknown|None|None
48390|f1635c9fd238431abae8af61d795c00f|Ontario||None|None|None|8657995
48391|c8b912c0e7db4f1baea99b9e4f0d0281|Ontario|National Road Network - 
48391|c8b912c0e7db4f1baea99b9e4f0d0281|Ontario|Réseau Routier National 
48391|c8b912c0e7db4f1baea99b9e4f0d0281|Ontario|V1.0|5|GPS|Federal|2001/0
48391|c8b912c0e7db4f1baea99b9e4f0d0281|Ontario|6|Local / 
48391|c8b912c0e7db4f1baea99b9e4f0d0281|Ontario|Street|None|None|None|Non
48391|c8b912c0e7db4f1baea99b9e4f0d0281|Ontario|e|None|None|None|None|Non
48391|c8b912c0e7db4f1baea99b9e4f0d0281|Ontario|e|None|None|None|None|Non
48391|c8b912c0e7db4f1baea99b9e4f0d0281|Ontario|e|2|Paved 
48391|c8b912c0e7db4f1baea99b9e4f0d0281|Ontario|Surface|Unknown|None|None
48391|c8b912c0e7db4f1baea99b9e4f0d0281|Ontario||None|None|None|8657996
...

So it looks like the attributes got read in.

The machine I did the test on is a Fedora Core3 box with Grass6.1

Hope this helps...

Aaron

+----------------------------------------+
| Aaron Racicot  | aaronr at ecotrust.org   |
| GIS Programmer | 503.467.0759          |
+----------------------------------------+
| e c o t r u s t                        |
| Jean Vollum Natural Capital Center     |
| 721 NW Ninth Avenue                    |
| Suite 200                              |
| Portland, OR 97209                     |
| www.ecotrust.org                       |
+----------------------------------------+
-----Original Message-----
From: grassuser-bounces at grass.itc.it [mailto:grassuser-bounces at grass.itc.it] On Behalf Of Sampson, David
Sent: Thursday, August 10, 2006 10:55 AM
To: grassuser at grass.itc.it
Subject: [GRASS-user] V.in.ogr error processing shape file from GEOBASE. Anyother experieinces?


Hey Folks. 
I was wondering someone else can test out this dataset and let me know if they can make it import... 
Data source: http://www.geobase.ca/geobase/en/data/nrnc1.html
Province: Ontario
Archive: NRNC1_ON_SHAPE_en
File: ROADSEG
A free account is required to download the dataset. 
System: 
------------
Linux (Gentoo)
Grass 6.0.2 and 6.1 


Problem: 
-------------
When importing regularly with attribute tables the process halts part way through. Not all the vectors are imported. There are lots of holes left in the dataset. The error was refering to incorrect format of a column....


Current Solution: 
-------------------------- 
Importing vector shape without attribute table. All the vecotrs import without holes. However, of course I'd like to have the attribute tables
Next attempt to work around 
----------------------------------------- 
Never tried anything like this before but I'll try to just move the DBF file over to the DBF directory and try to connect to it manualy. I'm sure there will be a disconect somehow. If you have experience with this approach then let me know.


Thanks 




More information about the grass-user mailing list