Bug report #7427
cannot import postgis layers into GRASS mapset
Status: | Closed | ||
---|---|---|---|
Priority: | Severe/Regression | ||
Assignee: | Radim Blazek | ||
Category: | GRASS | ||
Affected QGIS version: | master | Regression?: | No |
Operating System: | Easy fix?: | No | |
Pull Request or Patch supplied: | No | Resolution: | |
Crashes QGIS or corrupts data: | No | Copied to github as #: | 16389 |
Description
it works on 1.8
tested with osgeo4w, so using the very same GRASS version.
The output of v.in.ogr is
Layer not available
Finished with error
while on 1.8 it runs normally.
Associated revisions
GRASS v.in.ogr.qgis postgres - set schemas option, fixes #7427
History
#1 Updated by Radim Blazek over 11 years ago
- Assignee set to Radim Blazek
- Status changed from Open to Feedback
Does it work if you run the GRASS module from GRASS shell?
Are module parameters generated by QGIS the same in 1.8 and 1.9? Paste here both please.
Which module exactly do you refer to? v.in.ogr.qgis?
#2 Updated by Giovanni Manghi over 11 years ago
- Status changed from Feedback to Open
Radim Blazek wrote:
Does it work if you run the GRASS module from GRASS shell?
Are module parameters generated by QGIS the same in 1.8 and 1.9? Paste here both please.
Which module exactly do you refer to? v.in.ogr.qgis?
Just tested and I still see it, using the very same PostGIS layer on both 1.8 and master with the module v.in.ogr.qgis and the same mapset.
The error on master is the same as above
v.in.ogr "dsn=PG:dbname='postgis20' host=localhost port=5432 user='postgres' password='gio' sslmode=disable" layer=public.zpe output=zpe19 snap=-1 min_area=0.0001 -o
Layer not available
Finished with error
From the GRASS CLI it does not work either
C:\\>v.in.ogr "dsn=PG:dbname='postgis20' host=localhost port=5432 user='postgres'
password='gio' sslmode=disable" layer=public.zpe output=zpe19_cli snap=-1 min_a
rea=0.0001 -o
GRASS_INFO_ERROR(7984,1): Layer <public.zpe> not available
GRASS_INFO_END(7984,1)
but should not be a GRASS issue as both 1.8 and master are using the same GRASS install (osgeo4w).
on 1.8 the log says
v.in.ogr "dsn=PG:dbname='postgis20' host=localhost port=5432 user='postgres' password='gio' sslmode=disable" layer=zpe output=zpe18 snap=-1 min_area=0.0001 -o
Se sobrepondo � verifica��o da proje��o
Layer: zpe
Default driver / database set to:
driver: dbf
database: $GISDBASE/$LOCATION_NAME/$MAPSET/dbf/
Counting polygons for 43 features...
Importanto fei��es do mapa 43...
Building topology for vector map ...
Registering primitives...
228 primitives registered
100615 vertices registered
Number of nodes: 218
Number of primitives: 228
Number of points: 0
Number of lines: 0
Number of boundaries: 228
Number of centroids: 0
Number of areas: -
Number of isles: -
Cleaning polygons, result is not guaranteed!
Break polygons:
Remove duplicates:
Break boundaries:
Remove duplicates:
Clean boundaries at nodes:
Merge boundaries:
Change dangles to lines:
Remove bridges:
Building topology for vector map ...
Building areas...
132 areas built
40 isles built
Attaching islands...
Number of nodes: 981
Number of primitives: 1266
Number of points: 0
Number of lines: 0
Number of boundaries: 1266
Number of centroids: 0
Number of areas: 132
Number of isles: 40
Number of areas without centroid: 132
Find centroids for layer: zpe
Write centroids:
46 �reas representam mais fei��es (sobreposi��o) , pois os pol�gonos se sobrep�e na(s) camada(s) de entrada. Estas �reas est�o ligadas a mais de uma linha na tabela de atributos. O n�mero de fei��es para essas �reas est� armazenado com categoria na camada 2
60 input polygons
Total area: 9.99292E+009 (132 areas)
Overlapping area: 262534 (46 areas)
Area without category: 8.76006E+006 (44 areas)
Building topology for vector map ...
Registering primitives...
330 primitives registered
101267 vertices registered
Building areas...
132 areas built
40 isles built
Attaching islands...
Attaching centroids...
Number of nodes: 238
Number of primitives: 330
Number of points: 0
Number of lines: 0
Number of boundaries: 242
Number of centroids: 88
Number of areas: 132
Number of isles: 40
Number of areas without centroid: 44
Errors were encountered during the import
Try to import again, snapping with at least 1e-010: 'snap=1e-010'
Concluído com sucesso
#3 Updated by Radim Blazek over 11 years ago
The problem is schema name in layer parameter. I'll fix that.
#4 Updated by Radim Blazek over 11 years ago
- Status changed from Open to Closed
Fixed in changeset 8a932d294a1fcafc97e1e255f47eb6764de9aa59.