[GRASS-user] RE: RE: I can't import postgis layer using v.in.ogr in WinGRASS (Pablo Carreira)

4. RE: I can?t import postgis layer using v.in.ogr in WinGRASS
(Pablo Carreira)

Hi Pablo. I used your sugestion (without “”) and recieve these messages:

Sorry, <host> is not a valid parameter
Sorry, <user> is not a valid parameter
Sorry, <password> is not a valid parameter

:frowning:

Another sugestion?

Best regards.

Thybério Luna Freire

-------Original Message-------

From: grass-user-request@lists.osgeo.org
Date: 10/3/2010 00:43:29
To: grass-user@lists.osgeo.org
Subject: grass-user Digest, Vol 47, Issue 26

Send grass-user mailing list submissions to
grass-user@lists.osgeo.org

To subscribe or unsubscribe via the World Wide Web, visit
http://lists.osgeo.org/mailman/listinfo/grass-user
or, via email, send a message with subject or body ‘help’ to
grass-user-request@lists.osgeo.org

You can reach the person managing the list at
grass-user-owner@lists.osgeo.org

When replying, please edit your Subject line so it is more specific
than “Re: Contents of grass-user digest…”

Today’s Topics:

  1. I can?t import postgis layer using v.in.ogr in WinGRASS
    (Thyb?rio Luna Freire)
  2. ps.map: One Script Works, One Doesn’t (Rich Shepard)
  3. Re: ps.map: One Script Works, One Doesn’t (Rich Shepard)
  4. RE: I can?t import postgis layer using v.in.ogr in WinGRASS
    (Pablo Carreira)
  5. Re: ps.map: One Script Works, One Doesn’t (Rich Shepard)
  6. Re: Running Python scripts inside GRASS (Milton Cezar Ribeiro)
  7. Re: ps.map: One Script Works, One Doesn’t (Rich Shepard)
  8. Re: ps.map: One Script Works, One Doesn’t (Hamish)
  9. Re: ps.map: One Script Works, One Doesn’t (Rich Shepard)
  10. Re: ps.map: One Script Works, One Doesn’t (Dave Kent)

Message: 1
Date: Tue, 9 Mar 2010 16:21:53 -0300
From: Thyb?rio Luna Freire <thyberio@gmail.com>
Subject: [GRASS-user] I can?t import postgis layer using v.in.ogr in
WinGRASS
To: grass-user@lists.osgeo.org, grass-stats-request@lists.osgeo.org
Message-ID:
<9e23a6811003091121h43dee098s5c86b29975a2a355@mail.gmail.com>
Content-Type: text/plain; charset=“iso-8859-1”

Hi,
I´m a Linux/Windows user. Using GRASS in my Ubuntu, i can import postgis
layers by v.in.ogr with facility. But, in my job, the OS used is Windows and
i use WinGRASS.
I just installed PostgreSQL/Postgis to manage my data.
I transfered the db administration to pg:

db.connect driver=pg database=“host=localhost, dbname=gis”
db.login driver=pg database=gis user=postgres pass=
*****

until that, all ok…but when:

*v.in.ogr dsn=“PG:host=localhost dbname=gis user=postgres” layer=Municipios
output=Municipios
*
i recieve the following message:

ERROR: Unable to open data source <"PG:host=localhost dbname=gis
user=postgres…

I searched in all documents and sites and i didn’t find any answer.

I need help.

Thanks!

Thybério Luna Freire - Brazil
-------------- next part --------------
An HTML attachment was scrubbed…
URL: http://lists.osgeo.org/pipermail/grass-user/attachments/20100309/95e77be8/attachment-0001.html


Message: 2
Date: Tue, 9 Mar 2010 11:35:02 -0800 (PST)
From: Rich Shepard <rshepard@appl-ecosys.com>
Subject: [GRASS-user] ps.map: One Script Works, One Doesn’t
To: grass-users@lists.osgeo.org
Message-ID:
<alpine.LNX.2.00.1003091129320.14989@salmo.appl-ecosys.com>
Content-Type: TEXT/PLAIN; format=flowed; charset=US-ASCII

This has been wasting my time this morning and I’d sure like to learn why.

I have two ps.map input scripts called ‘flowlinedensity.psmap’ and
‘slopes.psmap’. They both compile, but when I view the latter I get a
ghostscript error box, no colortable, and no points legend in the v.legend
area.

Running diff on the two scripts shows only this:

1c1
< raster aber10m.flowdensityAvg

> raster aber10m.slope
48c48
< text 78% 28% Flow Line\n Densities

> text 77% 30% Slope (Degrees)
58c58
< range 0 100

> range 0 25

Since the only differences are the base raster map, text position and
content, and colortable range I fail to see why the latter throws a gv
error.

If I remove the vlegend clause it displays.

Any ideas?

Rich


Message: 3
Date: Tue, 9 Mar 2010 11:45:50 -0800 (PST)
From: Rich Shepard <rshepard@appl-ecosys.com>
Subject: Re: [GRASS-user] ps.map: One Script Works, One Doesn’t
To: grass-users@lists.osgeo.org
Message-ID:
<alpine.LNX.2.00.1003091144400.14989@salmo.appl-ecosys.com>
Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed

On Tue, 9 Mar 2010, Rich Shepard wrote:

> I have two ps.map input scripts called ‘flowlinedensity.psmap’ and
> ‘slopes.psmap’. They both compile, but when I view the latter I get a
> ghostscript error box, no colortable, and no points legend in the v.legend
> area.

I should mention that of the 5 maps in the report, the slopes map is the
only one that balks at displaying properly. The only differences are the
base raster and the text contents.

Rich


Message: 4
Date: Tue, 9 Mar 2010 16:48:59 -0300
From: Pablo Carreira <pablotcarreira@hotmail.com>
Subject: RE: [GRASS-user] I can?t import postgis layer using v.in.ogr
in WinGRASS
To: <thyberio@gmail.com>, <grass-user@lists.osgeo.org>
Message-ID: <SNT114-W32657C8DA7DE09E9A44D72D6340@phx.gbl>
Content-Type: text/plain; charset=“iso-8859-1”

Hi Thyberio,

>until that, all ok…but when:

>v.in.ogr dsn=“PG:host=localhost dbname=gis user=postgres” layer=Municipios output=Municipios
>i recieve the following message:
>ERROR: Unable to open data source <"PG:host=localhost dbname=gis user=postgres…

Try:
v.in.ogr dsn=PG:dbname=gis host=localhost user=postgres password=******** output=Municipios

Note there is no “” . If it does not work please paste the full error report.
Make sure that pg server is running.

Pablo.


Navegue sem medo: O Internet Explorer 8 te deixa mais protegido. Baixe gratuitamente.
http://go.microsoft.com/?linkid=9707132
-------------- next part --------------
An HTML attachment was scrubbed…
URL: http://lists.osgeo.org/pipermail/grass-user/attachments/20100309/a1ac5b6f/attachment-0001.html


Message: 5
Date: Tue, 9 Mar 2010 13:15:41 -0800 (PST)
From: Rich Shepard <rshepard@appl-ecosys.com>
Subject: Re: [GRASS-user] ps.map: One Script Works, One Doesn’t
To: grass-users@lists.osgeo.org
Message-ID:
<alpine.LNX.2.00.1003091314350.14989@salmo.appl-ecosys.com>
Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed

On Tue, 9 Mar 2010, Rich Shepard wrote:

> I should mention that of the 5 maps in the report, the slopes map is the
> only one that balks at displaying properly.

More testing reveals the problem is with the slope raster map. What in
that particular map might cause an issue with vlegend?

Rich


Message: 6
Date: Tue, 9 Mar 2010 16:22:03 -0500
From: Milton Cezar Ribeiro <miltinho.astronauta@gmail.com>
Subject: Re: [GRASS-user] Running Python scripts inside GRASS
To: Hamish <hamish_b@yahoo.com>
Cc: Sonja Jankowfsky <sonja.jankowfsky@cemagref.fr>, GRASS user list
<grass-user@lists.osgeo.org>, Glynn Clements
<glynn@gclements.plus.com>
Message-ID:
<64f1583f1003091322m702ade4au536045fc8e238d82@mail.gmail.com>
Content-Type: text/plain; charset=“iso-8859-1”

Hi There,

I am happy running python inside a OSGeo4W grass instalallation.
I start MSYS, start grass, and then ryn python 2.5 which are run
from C:\OSGeo4W\apps\Python25. But I needed to copy the grass/python
library to C:\OSGeo4W\apps\Python25\Lib\site-packages.
Good luck,

milton

2010/3/9 Hamish <hamish_b@yahoo.com>

> Sonja wrote:
> > Is there any other place where a wrong PYTHONPATH could be stored???
>
> if you have the grass source code try from the the msys prompt:
>
> grep -ri python25 mswindows/*
>
>
> wingrass is a bit of a tangle of startup scripts, especially the osgeo4w
> build. the above searches through the custom/lesser known wingrass ones.
>
>
> you can also try a recursive grep in the GRASS-64-SVN\ directory to try
> and find and. If doing that I’d add the -I flag to skip searching in
> binaries.
>
>
>
> Hamish
>
>
>
>
> _______________________________________________
> grass-user mailing list
> grass-user@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/grass-user
>
-------------- next part --------------
An HTML attachment was scrubbed…
URL: http://lists.osgeo.org/pipermail/grass-user/attachments/20100309/77109c37/attachment-0001.html


Message: 7
Date: Tue, 9 Mar 2010 13:22:33 -0800 (PST)
From: Rich Shepard <rshepard@appl-ecosys.com>
Subject: Re: [GRASS-user] ps.map: One Script Works, One Doesn’t
To: grass-users@lists.osgeo.org
Message-ID:
<alpine.LNX.2.00.1003091321420.14989@salmo.appl-ecosys.com>
Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed

On Tue, 9 Mar 2010, Rich Shepard wrote:

> This has been wasting my time this morning and I’d sure like to learn why.

Fixed it. I re-created the slopes map (r.slope.aspect) and that did the
trick. No idea what was wrong with the original, but something definitely
was.

Rich


Message: 8
Date: Tue, 9 Mar 2010 15:28:06 -0800 (PST)
From: Hamish <hamish_b@yahoo.com>
Subject: Re: [GRASS-user] ps.map: One Script Works, One Doesn’t
To: grass-users@lists.osgeo.org, Rich Shepard
<rshepard@appl-ecosys.com>
Message-ID: <67948.82195.qm@web110007.mail.gq1.yahoo.com>
Content-Type: text/plain; charset=iso-8859-1

Rich wrote:
> I have two ps.map input scripts called
> ‘flowlinedensity.psmap’ and
> ‘slopes.psmap’. They both compile, but when I view the
> latter I get a
> ghostscript error box, no colortable, and no points legend
> in the v.legend
> area.
>
> Running diff on the two scripts shows only this:
>
> 1c1
> < raster aber10m.flowdensityAvg
> —
> > raster aber10m.slope
> 48c48
> < text 78% 28% Flow Line\n Densities
> —
> > text 77% 30% Slope (Degrees)

> Since the only differences are the base raster map,
> text position and content, and colortable range I fail
> to see why the latter throws a gv error.
>
> If I remove the vlegend clause it displays.
>
> Any ideas?

text 77% 30% Slope (Degrees)

( and ) need to be quoted like ( and ).

see the documentation for the “comments” instruction, I guess it
applies to “text” as well.

PostScript uses () as the beginning/end delimiter for text
strings.

Hamish


Message: 9
Date: Tue, 9 Mar 2010 16:19:27 -0800 (PST)
From: Rich Shepard <rshepard@appl-ecosys.com>
Subject: Re: [GRASS-user] ps.map: One Script Works, One Doesn’t
To: grass-users@lists.osgeo.org
Message-ID:
<alpine.LNX.2.00.1003091617500.14989@salmo.appl-ecosys.com>
Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed

On Tue, 9 Mar 2010, Hamish wrote:

> text 77% 30% Slope (Degrees)
> ( and ) need to be quoted like ( and ).

Hamish,

Actually, they don’t. Originally I had the string in quotes and those
printed, too. The above prints quite well.

As I wrote to the list, I isolated the problem to the base raster map.
Regenerating that fixed the problem.

Thanks,

Rich


Message: 10
Date: Tue, 09 Mar 2010 21:35:28 -0600
From: Dave Kent <dkent@sasktel.net>
Subject: Re: [GRASS-user] ps.map: One Script Works, One Doesn’t
To: Rich Shepard <rshepard@appl-ecosys.com>
Cc: grass-users@lists.osgeo.org
Message-ID: <2238A0B6-FF1C-481F-B50E-3F367FB8BA32@sasktel.net>
Content-Type: text/plain; charset=us-ascii

I am having a similar, perhaps related problem.

I have a raster image overlain by a series of vectors.

ps.map fails erratically.

If I remove the raster, it works.

If I remove v.legend, it works. (legend only for vector features)

If I make one specific item in the legend as – lpos 0 – it works.

When all are present in the script, it fails.

When I try to make a pdf with Distiller, the “offending error” is a long numeric string approximately 100 digits long. I opened the postscript file in a text editor and the long string seemed to be associated with the legend. After editing the string, I could open the postscript file.

In other mapsets, things work fine.

The problem appears to be associated with the legend. i have no idea why there is any link with the raster image.

Mac, Snow Leopard, Grass 6.4RC3, Mr. Kyngesburye’s binaries updated today.

Dave

On 2010-03-09, at 6:19 PM, Rich Shepard wrote:

> On Tue, 9 Mar 2010, Hamish wrote:
>
>> text 77% 30% Slope (Degrees)
>> ( and ) need to be quoted like ( and ).
>
> Hamish,
>
> Actually, they don’t. Originally I had the string in quotes and those
> printed, too. The above prints quite well.
>
> As I wrote to the list, I isolated the problem to the base raster map.
> Regenerating that fixed the problem.
>
> Thanks,
>
> Rich
> _______________________________________________
> grass-user mailing list
> grass-user@lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/grass-user



grass-user mailing list
grass-user@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/grass-user

End of grass-user Digest, Vol 47, Issue 26


[FREE Animations for your email - by IncrediMail! Click Here!](http://www.incredimail.com/?id=606430&rui=124945965)
(attachments)

faint_grain.jpg



Hi Pablo. I used your sugestion (without “”) and recieve these messages:

Sorry, is not a valid parameter
Sorry, is not a valid parameter
Sorry, is not a valid parameter

:frowning:

Another sugestion?

Best regards.

Thybério Luna Freire