Sponsored Content
The Lounge What is on Your Mind? How much snow do you have where you are? Post 302097966 by vino on Wednesday 29th of November 2006 11:10:50 PM
Old 11-30-2006
No snow in Bangalore, India. And none expected for years to come!!
 

4 More Discussions You Might Find Interesting

1. OS X (Apple)

MacPorts on Snow Leopard

Hello everyone. I was previously using MacPorts 1.8 on Mac OS 10.5.8 without any problems and everything was working well. I recently upgraded to Xcode 3.2 and Mac OS 10.6, since then my MacPorts installation has not been working at all. I deleted it and then reinstalled the .dmg from the... (1 Reply)
Discussion started by: HoldenCaulfield
1 Replies

2. OS X (Apple)

Alpine 2 on Snow Leopard

I've just installed Alpine on Snow Leopard but can't seem to get a default spell checker configured for it. What happened to spell? I can't find it at all on 10.6, must have been some changes. Does anyone know about the default unix spell checker on SL? Thanks! (0 Replies)
Discussion started by: platz
0 Replies

3. OS X (Apple)

Installing Oracle 10g on Snow Leopard using this tutorial

This tutorial. Which is a lovely tutorial, really, and was working up until this instruction: Now download db.zip installation archive and place it somewhere and unzip it: mkdir Install cd Install # download db.zip to this directory unzip db.zip cd db/Disk1 I didn't know how to... (1 Reply)
Discussion started by: khayraB
1 Replies

4. OS X (Apple)

Problem with mail attachment in Snow Leopard

Hi, We have few scripts that are run through jobs . It sends us daily reports (using mailx). This was working fine in Leopard. But in Snow Leopard there is problem with the attachments.Neither the attachment name is being displayed correctly(all it displays is "Mail Attachment") nor the format... (1 Reply)
Discussion started by: adash
1 Replies
shp2pgsql(1)							      PostGIS							      shp2pgsql(1)

NAME
shp2pgsql - shapefile to postgis loader SYNTAX
shp2pgsql [options] shapefile [schema.]table DESCRIPTION
The shp2pgsql data loader converts ESRI Shape files into SQL suitable for insertion into a PostGIS/PostgreSQL database. Version: 1.1.5 (2006/10/06) USAGE
The <shapefile> is the name of the shape file, without any extension information. For example, 'roads' would be the name of the shapefile comprising the 'roads.shp', 'roads.shx', and 'roads.dbf' files. The <tablename> is the (optionally schema-qualified) name of the database table you want the data stored in in the database. Within that table, the geometry will be placed in the 'geo_value' column by default. OPTIONS
The loader has several operating modes distinguished by command line flags: (Note that -a, -c, -d and -p are mutually exclusive.) -d Drops the database table before creating a new table with the data in the Shape file. -a Appends data from the Shape file into the database table. Note that to use this option to load multiple files, the files must have the same attributes and same data types. -c Creates a new table and populates it from the Shape file. This is the default mode. -p Only produces the table creation SQL code, without adding any actual data. This can be used if you need to completely separate the table creation and data loading steps. -D Use the PostgreSQL "dump" format for the output data. This can be combined with -a, -c and -d. It is much faster to load than the default "insert" SQL format. Use this for very large data sets. -s <SRID> Creates and populates the geometry tables with the specified SRID. -g <geometry_column> Specify the name of the geometry column (mostly useful in append mode). -k Keep idendifiers case (column, schema and attributes). Note that attributes in Shapefile are usually all UPPERCASE. -i Coerce all integers to standard 32-bit integers, do not create 64-bit bigints, even if the DBF header signature appears to warrant it. -S Generate simple Geometries instead of MULTIgeometries. Shape files don't differ between LINESTRINGs and MULTILINESTRINGs, so shp2pgsql generates MULTILINESTRINGs by default. This switch will produce LINESTRINGs instead, but shp2pgsql will fail when it hits a real MULTILINESTRING. The same works for POLYGONs vs. MULTIPOLYGONs. -w Output WKT format, for use with older (0.x) versions of PostGIS. Note that this will introduce coordinate drifts and will drop M values from shapefiles. -W <encoding> Specify the character encoding of Shapefile's attributes. If this option is used the output will be encoded in UTF-8. -I Create a GiST index on the geometry column. -N <policy> Specify NULL geometries handling policy (insert,skip,abort). -? Display version and usage information. INSTALLATION
To compile the program from source, simply run "make" in the source directory. Then copy the binary in your shell search path (or wherever you like). This text is also available as a man page in the ../doc/man/ directory, ready for copying it into the manual search path on unixoid systems. EXAMPLES
An example session using the loader to create an input file and uploading it might look like this: # shp2pgsql shaperoads roadstable roadsdb > roads.sql # psql -d roadsdb -f roads.sql A conversion and upload can be done all in one step using UNIX pipes: # shp2pgsql shaperoads roadstable roadsdb | psql -d roadsdb AUTHORS
Originally written by Jeff Lounsbury <jeffloun@refractions.net>. Improved and maintained by Sandro Santilli <strk@refractions.net>. Includes small contributions and improvements by others. This application uses functionality from shapelib 1.2.9 by Frank Warmerdam <warmerda@gdal.velocet.ca> to read from ESRI Shape files. SEE ALSO
pgsql2shp(1) More information is available at http://postgis.refractions.net shp2pgsql(1)
All times are GMT -4. The time now is 11:06 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy