GPSFileDepot.com
 

News:

Welcome to GPSFileDepot!

Main Menu

can not see it

Started by deepspace, December 04, 2008, 01:16:12 PM

Previous topic - Next topic

deepspace

Hi, Forgive me if this is obvious (I did search the forum for a answer first) but I am trying to make a top mapo of just the Olympic Peninsula in my first attempt at this.
I think I have everything I need. When attempting to work with the NHD files in the command line I get this:

C:\Program Files\PostgreSQL\8.3\bin>shp2pgsql "C:\My Documents\washington\hydro\
NHDArea.shp" NHD_Area > nhd_area.sql
C:\My Documents\washington\hydro\NHDArea.shp: shape (.shp) or index files (.shx)
can not be opened, will just import attribute data.
C:\My Documents\washington\hydro\NHDArea.shp: dbf file (.dbf) can not be opened.
C:\Program Files\PostgreSQL\8.3\bin>
As one cane see the path appears correct because of the initial action it takes but I can not get any where else. Does any one see the mistake. Thank you in advance for any help.
I have fw tool installed, when I drag the shape files to the merge .bat files the black command screen comes up but disappears so fast I can not read what it does.
Maybe it there?
Cheers-Marc

-Oz-

At first glance it appears that there is a permission issue.

Are those shape files open when it tries to access them?

Also, normally C:\My Documents doesn't actually exist.  Its normally C:\Documents and Settings\User\My Documents

That is why I work in a C:\maps folder. Makes life a lot easier.  matter of fact I'm pretty sure that's the error.
Dan Blomberg
Administrator - GPSFileDepot
GPS Units: Garmin Dakota 20, Garmin GPSMap 60csx, Nuvi 255W, Nuvi 250W, ForeRunner 110, Fenix 2, Tactix Bravo, Foretrex 401
See/Download My Maps!

deepspace

That makes a lot of sense. I will work on today. Thanks for the quick help.
Cheers-Marc

deepspace

Ok that worked, I got to the next step no problems but trying to export it to the correct folder as .shp file keeps bringing up a error like:
C:\Program Files\PostgreSQL\8.3\bin>pgsql2shp  -f "C:\washington\hydro\Area.shp"
Waterbody.shp" -u postgres postgis nhd_waterbody

**ERROR** invalid option or command parameters

RCSID: $Id: pgsql2shp.c 2762 2008-04-10 14:44:26Z pramsey $ RELEASE: 1.3.3
USAGE: pgsql2shp [<options>] <database> [<schema>.]<table>
       pgsql2shp [<options>] <database> <query>
and of course it has a help file with the command letters.
I made sure the folders where not open so there would not be a permissions issue and get the same thing. Did I miss a step?
Cheers-Marc

-Oz-

QuoteC:\Program Files\PostgreSQL\8.3\bin>pgsql2shp  -f "C:\washington\hydro\Area.shp"
Waterbody.shp"
-u postgres postgis nhd_waterbody

The red part seems like your issue.  You can't have The area" and waterbody.
Dan Blomberg
Administrator - GPSFileDepot
GPS Units: Garmin Dakota 20, Garmin GPSMap 60csx, Nuvi 255W, Nuvi 250W, ForeRunner 110, Fenix 2, Tactix Bravo, Foretrex 401
See/Download My Maps!

deepspace

not sure how I got those 2 in one line I tried so many things.
Here it is again with correct lines:

C:\Program Files\PostgreSQL\8.3\bin>pgsql2shp  -f "C:\washington\hydro\Area.shp"
-u postgres -p postgis nhd_area

**ERROR** invalid option or command parameters

RCSID: $Id: pgsql2shp.c 2762 2008-04-10 14:44:26Z pramsey $ RELEASE: 1.3.3
USAGE: pgsql2shp [<options>] <database> [<schema>.]<table>
       pgsql2shp [<options>] <database> <query>

OPTIONS:
  -f <filename>  Use this option to specify the name of the file
     to create.
  -h <host>  Allows you to specify connection to a database on a
     machine other than the default.
  -p <port>  Allows you to specify a database port other than the default.
  -P <password>  Connect to the database with the specified password.
  -u <user>  Connect to the database as the specified user.
  -g <geometry_column> Specify the geometry column to be exported.
  -b Use a binary cursor.
  -r Raw mode. Do not assume table has been created by
     the loader. This would not unescape attribute names
     and will not skip the 'gid' attribute.
  -k Keep postgresql identifiers case.
  -? Display this help screen.

deepspace

Using the same methods everything worked out fine for transportation, but the hydro still has the same error. Thanks again for all the help, it feels as though I am almost there, great site.
Cheers-Marc

deepspace

I found the error. Thank you again for the help.

-Oz-

Glad you found it.  Was the order incorrect?  It seems like you were trying to do the wrong step with those parameters.
Dan Blomberg
Administrator - GPSFileDepot
GPS Units: Garmin Dakota 20, Garmin GPSMap 60csx, Nuvi 255W, Nuvi 250W, ForeRunner 110, Fenix 2, Tactix Bravo, Foretrex 401
See/Download My Maps!

deepspace

yes that was the error, case of can not see the problem staring right at the mistake. Now I am wrestling with what appears to be a common issue: DEM2TOPO and memory.
Read this post:    
http://forums.gpsfiledepot.com/index.php/topic,63.0.html but really it does not make sense to me how I control splitting the files into smaller segments with the command.
I searched the net and found no other solutions to make the dem files into say 4 small files instead of 1 huge one.
Cheers-Marc

deepspace

well I actually mis-lead as to memory issue, problem is dem2topo gets to some point (say 1181 out 3417 intermediate contours) then just hangs there for hours doing nothing. So I need to use task manager to end the whole thing. I did turn off firewalls, anti virus programs in case they where some how interfering. Have you heard of such thing? Any suggestions?
Cheers-Marc

maps4gps

I am using GM in a Vista environment.  At 75-80% memory usage, GM terminates without a message. 

deepspace

I should have given more details. The DEM files are all about 235 megs, they have a lot of contours because of the Olympic mountains. I have the newest version of all of the software installed on a Toshiba laptop running xp with a gig of memory. I got the furthest on my last attempt all the way to 1411 out of 3417 intermediate contours.  ???
Cheers-Marc

deepspace

I am wondering at this point if since IDL is not licensed and in demo mode if its timing out. Any chance any one knows about this?

-Oz-

Have you tried using gdal_contour?  That is my new solution.  I wonder if it would work.

Third post down here has more details: http://forums.gpsfiledepot.com/index.php/topic,93.0.html
Dan Blomberg
Administrator - GPSFileDepot
GPS Units: Garmin Dakota 20, Garmin GPSMap 60csx, Nuvi 255W, Nuvi 250W, ForeRunner 110, Fenix 2, Tactix Bravo, Foretrex 401
See/Download My Maps!