geotiff2pgraster(1) PostGIS geotiff2pgraster(1) NAME geotiff2pgraster - geotiff to postgis/pgraster loader SYNTAX geotiff2pgraster [options] geotiff-file [[schema.]table] DESCRIPTION The geotiff2pgraster data loader converts GeoTIFF(georeferenced imag- es) directly into a PostGIS/PGRaster database. Version: 0.0.1 (2007/07/22) REFERENCE This programe learn some of its functionality from these similar programs: 1. psql - standard PostgreSQL client programe 2. shp2pgsql/pgsql2shp - PostGIS loader programmes for Shape files. 3. GDAL GeoTIFF - geotiff reader for GDAL programe. USAGE The is the pathname of the geotiff file with the extens- ion of one the fours: .tiff, .tif, .geotif, .geotiff. You should always specify a full path for the desitinate geotiff file. Otherwise this pr- ogram will search for the file in the name you input in the current wo- rking directory. The is the (optionally schema-qualified) name of the database table you want the data stored in in the database. Within cur- rent PostGIS/PGRaster schema, one single raster dataset will be stored seperately into two tables: PGRASTER_MEDATA and PGRASTER_DATA table. You can specify a name here for the PGRASTER_DATA table which will have the same structure with default template PGRASTER_DATA table. If this option is ignored, the same table name as the input filename will be u- sed. For examples: geotiff2pgraster [options...] us_tm19900710.geotiff Then the us_tm19900710 will be adopted as the data table name to store raster data. (TO BE CONTINUE...) OPTIONS The loader has several operating modes distinguished by command line flags: ####################### (NOT SUPPORTED YET) ######################### (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 geotiff file. -a Appends data from the geotiff file into the existing database table. Although it is not recommended to store raw data of sever- ral raster dataset into one raster data table (sharing). But if you insist, you can do it by this option. -c Creates a new table and populates it from the geotiff 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 sepa- rate the table creation and data loading steps. (NOT SUPPORTED YET) -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. If this option is set, then the following options could be ignored. ####################### (NOT SUPPORTED YET) ######################### -h The database host to connect to. If ignored, the default address of host will be "localhost/127.0.0.1". If no database running on this host, the program will exit immediately with a error msg. -p The port to connect to on the database host. If ignored, the standard port number of 5432 will be used.If no database running on this port, the program will exit immediately with a error msg. -d The database to use when connecting. If ignored, the current OS username will be used the name of database to login into. If this database is refused to login, the program will exit immediately with a error message. -P The password to use when connecting to the database. This option can't be ignored. If this password is refused to login, the pro- gram will exit immediately with a error message. -u The username to use when connecting to the database. If ignored, the current OS username will be used to login into the database. If this username is refused to login, the program will exit immediately with a error message. -k Keep idendifiers case (don't uppercase field names). -?/--help 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 upload- ing it might look like this: # geotiff2pgraster -d -h localhost -p 5432 -u postgres -P "password" -k "~/us_images/us_tm1990.tiff" AUTHORS Originally written and maintained by Xing Lin . This application uses functionality from shapelib 1.2.9 by Frank Warmerdam to read from ESRI Shape files. SEE ALSO pgraster2geotiff(1) More information is available at http://postgis.refractions.net Any problem with this programe, do contact xing . geotiff2pgraster(1)