Re: [postgis-users] pgsql2shp

2010-10-11 Thread Paragon Corporation
Bob,

You can ignore that notice.  If you are getting no data, then it usually
means your tables are empty or there is some other problem which it should
notify you of.

The "No proj file will be generated" is just a warning that your data will
lack the meta data required to reproject it with common GIS software like
ArcGIS or MapInfo.  If you don't care about people overlaying data in
various projections on top of yours, you can safely ignore that warning.

As Steve mentioned, its generally good to have a spatial reference system
defined for your data, but as we recall you saying in the past, you are
using PostGIS to do process modeling, so the whole spatial reference system
argument is pretty irrelevant for your purposes.

To answer your question -- 1.4 is not the latest on windows -- there is a
PostGIS 1.5.2 pgsql2shp which I think has some bug fixes that the 1.4 is
currently lacking.  If you don't want to install 1.5, you can just download
the binaries and use the packaged pgsql2shp in the bin folder.  It will work
fine with a  PostGIS 1.4 database.

http://www.postgis.org/download/windows/#windbinaries

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 Bob
Pawley
Sent: Monday, October 11, 2010 6:26 PM
To: PostGIS Users Discussion
Subject: Re: [postgis-users] pgsql2shp

The reason I asked is that I had tyo upgrade pgdump in order to get it to
work.

I'm using this (and variations of it)

pgsql2shp -f c:\user\bob\ShapeTest.shp -h localhost -u postgres -P
London2342 PDW
"Select the_geom from p_id.image where p_id_id = '1534'"

or

pgsql2shp -f myfile.shp -h localhost -u postgres -P London2342 PDW
p_id.image -g the_geom

The message just tells me that "No prj file will be generated".

I am using 8.4 if that helps.

Bob

--
From: "Mike Toews" 
Sent: Monday, October 11, 2010 1:30 PM
To: "PostGIS Users Discussion" 
Subject: Re: [postgis-users] pgsql2shp

> As far as I know, all versions of pgsql2shp work just fine on Win7, 
> and they should do exactly what they are documented to do for the 
> situation you describe. What exactly are your problems? If the command 
> had an error and didn't produce any files, what did you type?
>
> -Mike
>
> On 10 October 2010 14:03, Bob Pawley  wrote:
>> I'm still having problems.
>>
>> My pgsql2shp version is -
>> RCSID: $Id: pgsql2shp.c 4914 2009-11-27 18:12:43Z  pramsey $ RELEASE: 
>> 1.4 Is this the right version to be using on Win 7??
>>
>> Bob
>>
>> --
>> From: "Stephen Woodbridge" 
>> Sent: Sunday, October 10, 2010 11:14 AM
>> To: 
>> Subject: Re: [postgis-users] pgsql2shp
>>
>>> On 10/10/2010 1:52 PM, Bob Pawley wrote:

 Hi
 I am using the following
 pgsql2shp -f Test.shp -u postgres -P London2342 -k PDW p_id.image 
 -g the_geom to export a shape file from postgis.
 Even tho I specify a single geometry column to be exported I get 
 warnings that column names have been truncated.
>>>
>>> DBF files can only have a maximum of 11 character column names. You 
>>> probably have some that are longer. You can work around this problem 
>>> by using a query at the end of the commandline like:
>>>
>>> 'select col1, col2, col3whichisverylong as col3, ... the_geom from 
>>> p_id.image'
>>>
 Command prompt also informs me that "No prj file will be generated"
 Also a warning 'cannot determine spatial reference". I thought the 
 default was -1?
>>>
>>> -1 is the default and it means that you have not defined a 
>>> projection so it can not create a .prj file. It is generally a good 
>>> idea to always define a projection for your data.
>>>
>>> -Steve W
>>>
 I also get messages-
 "Done (postgis major version: 1)
 Output shape: Polyline
 Dumping: xx [8 rows]"
 What am I doing wrong???
 Bob



 ___
 postgis-users mailing list
 postgis-users@postgis.refractions.net
 http://postgis.refractions.net/mailman/listinfo/postgis-users
>>>
>>> ___
>>> postgis-users mailing list
>>> postgis-users@postgis.refractions.net
>>> http://postgis.refractions.net/mailman/listinfo/postgis-users
>>>
>> ___
>> postgis-users mailing list
>> postgis-users@postgis.refractions.net
>> http://postgis.refractions.net/mailman/listinfo/postgis-users
>>
> ___
> postgis-users mailing list
> postgis-users@postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
> 
___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


___
postgi

Re: [postgis-users] What is the last Windows Version of PostGISandPostgreSQL?

2010-10-11 Thread Paragon Corporation
Charles,
 
Not a stupid question.  Yes you have to install PostgreSQL 9.0 32-bit
version to use PostGIS 1.5.2 32-bit binaries
 
We are still working on the 64-bit PostGIS builds which we will post on
application stack builder when we are done.  We are hoping to be done in the
next 2-3 weeks or so.  Unfortunately time for us is short at the moment
since we are also trying to wrap up our final book edits for our upcoming
PostGIS in Action book.
 
Thanks for your patience,
Leo and Regina
http://www.postgis.us
 
 

  _  

From: postgis-users-boun...@postgis.refractions.net
[mailto:postgis-users-boun...@postgis.refractions.net] On Behalf Of Charles
Galpin
Sent: Monday, October 11, 2010 3:40 PM
To: PostGIS Users Discussion
Subject: Re: [postgis-users] What is the last Windows Version of
PostGISandPostgreSQL?


This may be a stupid question, so excuse me if it is :) 

Do I have to install the 32 bit version of postgresql 9.0 to use the 32 bit
PostGIS 1.5.2? I would think yes, but just want to make sure.

I want to install the latest and greatest on a 64 bit windows machine, and
just installed the 64 bit version of postgresql thinking that would be best.
It [still] doesn't show in stackbuilder for this install. 

thanks,
charles

On Oct 2, 2010, at 9:00 AM, Paragon Corporation wrote:


Tradecarto,
 
We haven't posted PostGIS 1.5.2 on StackBuilder yet, but you can download it
from 
http://www.postgis.org/download/windows/ (It will be the same setup files
we'll be posting to stack builder, so even if you use stack builder, it will
show as installed once we post them)
 
So as far as most up to date you can run on windows production:
 
PostGIS 1.5.2, PostgreSQL 9.0 32-bit, PgAdmin 1.120
So you can download PostgreSQL 9.0   from
http://www.enterprisedb.com/products/pgdownload.do#windows
 
PostGIS 1.5.2 from http://www.postgis.org/download/windows/ (and in the next
week from Application Stack Builder menu option in PostgreSQL)
 
 
-- experimental stuff
PostGIS 1.5.2 (we have PostGIS 2.0.0 experimental binaries too, but those
are just for testing -- not production use --
http://www.postgis.org/download/windows/experimental.php )
 
We'll be posting PostGIS 2.0.0 experimental binaries for PostgreSQL 9.1
alpha (32-bit) in the next week or so and updating hte otehrs as well to
reflect the latest changes in the upcoming PostGIS 2.0.0
 
Thanks,
Leo and Regina
http://www.postgis.us  
 
 


  _  

From: postgis-users-boun...@postgis.refractions.net
[mailto:postgis-users-boun...@postgis.refractions.net] On Behalf Of
Francisco José Reyes Peralta
Sent: Saturday, October 02, 2010 7:56 AM
To: postgis-users@postgis.refractions.net
Subject: [postgis-users] What is the last Windows Version of PostGIS
andPostgreSQL?


Dear friends,

What is the last version of PostGIS and PostgreSQL (pgAdmin III version
included) that I can install?

Where i can download and install in Windows XP Professional SP3?

Thanks you.
Tradecarto

___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users



___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


Re: [postgis-users] pgsql2shp

2010-10-11 Thread Bob Pawley
The reason I asked is that I had tyo upgrade pgdump in order to get it to 
work.


I'm using this (and variations of it)

pgsql2shp -f c:\user\bob\ShapeTest.shp -h localhost -u postgres -P 
London2342 PDW

"Select the_geom from p_id.image where p_id_id = '1534'"

or

pgsql2shp -f myfile.shp -h localhost -u postgres -P London2342 PDW 
p_id.image -g the_geom


The message just tells me that "No prj file will be generated".

I am using 8.4 if that helps.

Bob

--
From: "Mike Toews" 
Sent: Monday, October 11, 2010 1:30 PM
To: "PostGIS Users Discussion" 
Subject: Re: [postgis-users] pgsql2shp


As far as I know, all versions of pgsql2shp work just fine on Win7,
and they should do exactly what they are documented to do for the
situation you describe. What exactly are your problems? If the command
had an error and didn't produce any files, what did you type?

-Mike

On 10 October 2010 14:03, Bob Pawley  wrote:

I'm still having problems.

My pgsql2shp version is -
RCSID: $Id: pgsql2shp.c 4914 2009-11-27 18:12:43Z  pramsey $ RELEASE: 1.4
Is this the right version to be using on Win 7??

Bob

--
From: "Stephen Woodbridge" 
Sent: Sunday, October 10, 2010 11:14 AM
To: 
Subject: Re: [postgis-users] pgsql2shp


On 10/10/2010 1:52 PM, Bob Pawley wrote:


Hi
I am using the following
pgsql2shp -f Test.shp -u postgres -P London2342 -k PDW p_id.image -g
the_geom
to export a shape file from postgis.
Even tho I specify a single geometry column to be exported I get
warnings that column names have been truncated.


DBF files can only have a maximum of 11 character column names. You
probably have some that are longer. You can work around this problem by
using a query at the end of the commandline like:

'select col1, col2, col3whichisverylong as col3, ... the_geom from
p_id.image'


Command prompt also informs me that "No prj file will be generated"
Also a warning 'cannot determine spatial reference". I thought the
default was -1?


-1 is the default and it means that you have not defined a projection so
it can not create a .prj file. It is generally a good idea to always 
define

a projection for your data.

-Steve W


I also get messages-
"Done (postgis major version: 1)
Output shape: Polyline
Dumping: xx [8 rows]"
What am I doing wrong???
Bob



___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


[postgis-users] error with a $libdir variable defined in postgis.sql

2010-10-11 Thread Andrea Peri 2007




hi all,

i have downloaded the binaries for windows 32bit : postgis-pg90-binaries-2.0svn

when i proceed to run the batch file, this error appears and the whole
process goes wrong:

SET
BEGIN
psql:share/contrib/postgis-2.0/postgis.sql:59: ERROR:  could not
access file "$libdir/postgis-2.0": No such file or directory

any help would be appreciated

--
Victor


Have you modify the batch file "makepostgisdb.bat" for your configuration ?

Is necessary to set two variables with the right paths,

like this:

set PGBIN=C:\Program Files (x86)\PostgreSQL\9.0\bin\
set PGLIB=C:\Program Files (x86)\PostgreSQL\9.0\lib\

Regards,

Andrea Peri


___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


Re: [postgis-users] pgsql2shp

2010-10-11 Thread Mike Toews
As far as I know, all versions of pgsql2shp work just fine on Win7,
and they should do exactly what they are documented to do for the
situation you describe. What exactly are your problems? If the command
had an error and didn't produce any files, what did you type?

-Mike

On 10 October 2010 14:03, Bob Pawley  wrote:
> I'm still having problems.
>
> My pgsql2shp version is -
> RCSID: $Id: pgsql2shp.c 4914 2009-11-27 18:12:43Z  pramsey $ RELEASE: 1.4
> Is this the right version to be using on Win 7??
>
> Bob
>
> --
> From: "Stephen Woodbridge" 
> Sent: Sunday, October 10, 2010 11:14 AM
> To: 
> Subject: Re: [postgis-users] pgsql2shp
>
>> On 10/10/2010 1:52 PM, Bob Pawley wrote:
>>>
>>> Hi
>>> I am using the following
>>> pgsql2shp -f Test.shp -u postgres -P London2342 -k PDW p_id.image -g
>>> the_geom
>>> to export a shape file from postgis.
>>> Even tho I specify a single geometry column to be exported I get
>>> warnings that column names have been truncated.
>>
>> DBF files can only have a maximum of 11 character column names. You
>> probably have some that are longer. You can work around this problem by
>> using a query at the end of the commandline like:
>>
>> 'select col1, col2, col3whichisverylong as col3, ... the_geom from
>> p_id.image'
>>
>>> Command prompt also informs me that "No prj file will be generated"
>>> Also a warning 'cannot determine spatial reference". I thought the
>>> default was -1?
>>
>> -1 is the default and it means that you have not defined a projection so
>> it can not create a .prj file. It is generally a good idea to always define
>> a projection for your data.
>>
>> -Steve W
>>
>>> I also get messages-
>>> "Done (postgis major version: 1)
>>> Output shape: Polyline
>>> Dumping: xx [8 rows]"
>>> What am I doing wrong???
>>> Bob
>>>
>>>
>>>
>>> ___
>>> postgis-users mailing list
>>> postgis-users@postgis.refractions.net
>>> http://postgis.refractions.net/mailman/listinfo/postgis-users
>>
>> ___
>> postgis-users mailing list
>> postgis-users@postgis.refractions.net
>> http://postgis.refractions.net/mailman/listinfo/postgis-users
>>
> ___
> postgis-users mailing list
> postgis-users@postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
>
___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


Re: [postgis-users] What is the last Windows Version of PostGIS andPostgreSQL?

2010-10-11 Thread Charles Galpin
This may be a stupid question, so excuse me if it is :)

Do I have to install the 32 bit version of postgresql 9.0 to use the 32 bit 
PostGIS 1.5.2? I would think yes, but just want to make sure.

I want to install the latest and greatest on a 64 bit windows machine, and just 
installed the 64 bit version of postgresql thinking that would be best.   It 
[still] doesn't show in stackbuilder for this install. 

thanks,
charles

On Oct 2, 2010, at 9:00 AM, Paragon Corporation wrote:

> Tradecarto,
>  
> We haven't posted PostGIS 1.5.2 on StackBuilder yet, but you can download it 
> from
> http://www.postgis.org/download/windows/ (It will be the same setup files 
> we'll be posting to stack builder, so even if you use stack builder, it will 
> show as installed once we post them)
>  
> So as far as most up to date you can run on windows production:
>  
> PostGIS 1.5.2, PostgreSQL 9.0 32-bit, PgAdmin 1.120
> So you can download PostgreSQL 9.0   from 
> http://www.enterprisedb.com/products/pgdownload.do#windows
>  
> PostGIS 1.5.2 from http://www.postgis.org/download/windows/ (and in the next 
> week from Application Stack Builder menu option in PostgreSQL)
>  
>  
> -- experimental stuff
> PostGIS 1.5.2 (we have PostGIS 2.0.0 experimental binaries too, but those are 
> just for testing -- not production use -- 
> http://www.postgis.org/download/windows/experimental.php )
>  
> We'll be posting PostGIS 2.0.0 experimental binaries for PostgreSQL 9.1 alpha 
> (32-bit) in the next week or so and updating hte otehrs as well to reflect 
> the latest changes in the upcoming PostGIS 2.0.0
>  
> Thanks,
> Leo and Regina
> http://www.postgis.us
>  
>  
> 
> From: postgis-users-boun...@postgis.refractions.net 
> [mailto:postgis-users-boun...@postgis.refractions.net] On Behalf Of Francisco 
> José Reyes Peralta
> Sent: Saturday, October 02, 2010 7:56 AM
> To: postgis-users@postgis.refractions.net
> Subject: [postgis-users] What is the last Windows Version of PostGIS 
> andPostgreSQL?
> 
> Dear friends,
> 
> What is the last version of PostGIS and PostgreSQL (pgAdmin III version 
> included) that I can install?
> 
> Where i can download and install in Windows XP Professional SP3?
> 
> Thanks you.
> Tradecarto
> ___
> postgis-users mailing list
> postgis-users@postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users

___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


[postgis-users] error with a $libdir variable defined in postgis.sql

2010-10-11 Thread victor
hi all,

i have downloaded the binaries for windows 32bit : postgis-pg90-binaries-2.0svn

when i proceed to run the batch file, this error appears and the whole
process goes wrong:

SET
BEGIN
psql:share/contrib/postgis-2.0/postgis.sql:59: ERROR:  could not
access file "$libdir/postgis-2.0": No such file or directory

any help would be appreciated

--
Victor
___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


Re: [postgis-users] QGIS requires

2010-10-11 Thread Ivan Mincik

 On 10/11/2010 01:52 PM, William Furnass wrote:

Hi,

Aman: did you test your suggestion?  If you create a view from
(nextval('myseq') as id, geom, attr1, attr2) then QGIS will complain
that a layer cannot be created from that view as geom, attr1 and attr2
are not of suitable for use as a unique key (but does not even mention
the view field corresponding to the created sequence).  Bah.

Unfortunately the majority of the views I'd like to be able to view in
QGIS are derived from queries involving aggregate functions such as
ST_Union so I don't think recreating my tables with OIDS will help.


If You read QGIS requirements more closely, You will find that it 
requires that this column should be 'primary key, have a unique 
constraint on it, or be a PostgreSQL oid column.'

I am also surprised, that sequence column is missing.
This discussion should be definitely moved to Qgis developer list. Would 
You please make Your note to 'https://trac.osgeo.org/qgis/ticket/62' ?


--
Ivan Mincik, Gista s.r.o.

___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users


Re: [postgis-users] QGIS requires

2010-10-11 Thread William Furnass
Hi,

Aman: did you test your suggestion?  If you create a view from
(nextval('myseq') as id, geom, attr1, attr2) then QGIS will complain
that a layer cannot be created from that view as geom, attr1 and attr2
are not of suitable for use as a unique key (but does not even mention
the view field corresponding to the created sequence).  Bah.

Unfortunately the majority of the views I'd like to be able to view in
QGIS are derived from queries involving aggregate functions such as
ST_Union so I don't think recreating my tables with OIDS will help.

Will

On 18 August 2010 19:05, Aman Verma  wrote:
>
> First, you have to create a 'sequence'. But you only have to do this once. It 
> won't really matter if several different tables are using the same sequence 
> in your situation.
>
> create sequence sq; -- You only have to do this once. You could also make a 
> temporary sequence. create temporary...
>
> CREATE VIEW my_view AS (SELECT
> nextval('sq'), -- this is the function to access the next number from your 
> sequence.
> St_Union(wkb_geometry) FROM my_subregions GROUP BY region_id);
>
>
> -Original Message-
> From: postgis-users-boun...@postgis.refractions.net 
> [mailto:postgis-users-boun...@postgis.refractions.net] On Behalf Of William 
> Furnass
> Sent: August 18, 2010 1:52 PM
> To: PostGIS Users Discussion
> Subject: [postgis-users] QGIS requires
>
> QGIS requires that all PostGIS tables/views have a numeric primary
> key.  As a result I have had to create many temporary tables solely
> for the purpose of viewing the results of queries when ideally I would
> have liked to create views from the majority of my queries.  Does
> anyone know if I can create on-the-fly a serial numeric column in
> queries/views to save me having to create so many temporary tables?
> It'd be grand if something like the following were possible:
>
> CREATE VIEW my_view AS (SELECT numeric_id_generator(),
> St_Union(wkb_geometry) FROM my_subregions GROUP BY region_id);
___
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users