[GRASS-user] v.out.postgis

Paul Shapley p.shapley at gmail.com
Fri Jun 29 01:39:23 PDT 2018


Hi Markus,

OK here is the result of v.db.connect -p

v.db.connect -p
APGB_aerial_2_i_segment_drained_peat_with_exposed_haggs_vector
Vector map <APGB_aerial_2_i_segment_drained_peat_with_exposed_haggs_vector>
is connected by:
layer
<1/grass_gis.APGB_aerial_2_i_segment_drained_peat_with_exposed_haggs_vector>
table
<grass_gis.APGB_aerial_2_i_segment_drained_peat_with_exposed_haggs_vector>
in database <webgis> through driver <pg> with key <cat>

I recall some years ago you had to delete the 'db.login' file and recreate
it but this would lose the connection to the vector layer attribute table
(sqlite.db).

Thanks,

Paul Shapley

On 28 June 2018 at 13:22, Markus Metz <markus.metz.giswork at gmail.com> wrote:

>
>
> On Thu, Jun 28, 2018 at 1:40 PM, Moritz Lennert <
> mlennert at club.worldonline.be> wrote:
> >
> > On 28/06/18 09:59, Paul Shapley wrote:
> >>
> >> Hi,
> >>
> >> I am trying to export a vector map to PostGIS. Has anyone come across
> the 'Unable to describe table' error? I suspect my config could be wrong.
> >>
> >> v.out.postgis --overwrite input=APGB_aerial_2_i_segment_
> drained_peat_with_exposed_haggs_vct at PERMANENT output=PG:dbname=webgis
> output_layer=APGB_aerial_2_i_segment_drained_peat_with_exposed_haggs_vct
> options=FID=cat, GEOMETRY_NAME=wkb_geometry, SPATIAL_INDEX=YES,
> PRIMARY_KEY=YES
> >> DBMI-PostgreSQL driver error:
> >> select * from grass_gis.APGB_aerial_2_i_segment_drained_peat
> >> _with_exposed_haggs_vct where 1 = 0
> >> ERROR:  relation "grass_gis.apgb_aerial_2_i_segment_drained_
> >> peat_with_exposed_haggs_vct" does not exist
> >> LINE 1: select * from
> >> grass_gis.APGB_aerial_2_i_segment_drained_peat...
> >>                        ^
> >> DBMI-PostgreSQL driver error:
> >> select * from grass_gis.APGB_aerial_2_i_segment_drained_peat
> >> _with_exposed_haggs_vct where 1 = 0
> >> ERROR:  relation "grass_gis.apgb_aerial_2_i_segment_drained_
> >> peat_with_exposed_haggs_vct" does not exist
> >> LINE 1: select * from
> >> grass_gis.APGB_aerial_2_i_segment_drained_peat...
> >>                        ^
> >> *ERROR: Unable to describe table* <grass_gis.APGB_aerial_2_i_
> segment_drained_peat_with_exposed_haggs_vct>
> >
> >
> > It looks like it is trying to read the input attrubute table from
> postgresql (schema grass_gis). Do you use PostgreSQL as attribute table
> backend ? Could you provide the output of db.connect -p in that mapset ?
>
> ore precise would be
> v.db.connect -p APGB_aerial_2_i_segment_drained_peat_with_exposed_
> haggs_vct at PERMANENT
>
> because there may be a bug in v.out.postgis, not properly reading the
> database connection of the input vector.
>
> Markus Metz
>
> >
> > Moritz
> >
> > _______________________________________________
> > grass-user mailing list
> > grass-user at lists.osgeo.org
> > https://lists.osgeo.org/mailman/listinfo/grass-user
>
>


-- 
*Paul J. Shapley *MSc CGeog (GIS) FRGS
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/grass-user/attachments/20180629/4cf4b10c/attachment-0001.html>


More information about the grass-user mailing list