v.in.db driver=pg database="host=myserver.itc.it,dbname=mydb,user=name" \ table=pat_stazioni x=east y=north z=quota key=id output=pat_stazioni
2) Creating a map from PostGIS: To extract coordinate values from PostGIS, functions have to be used:
v.in.db driver=pg database="host=myserver.itc.it,dbname=mydb,user=name" \ table=station x="x(geom)" y="y(geom)" z="z(geom)" key=id out=meteostations
If an ID column is not not present in the PostgreSQL table,
the 'object ID' of PostgreSQL can be used. In this case set:
cat=OID
3) Import of a points table (x, y, z) from DBF file to vector points map:
#create vector map from DBF table (here, 'idcol' contains unique row IDs, 'z' is optional): #the 'database' parameter is the directory where the DBF file is stored: v.in.db driver=dbf database=/home/user/tables/ table=pointsfile x=x y=y z=z \ key=idcol out=dtmpoints #check result: v.info dtmpoints v.info -c dtmpoints
If an ID column is missing in the DBF file, it has to be added beforehand, e.g. with OpenOffice.
Last changed: $Date: 2006/02/21 18:46:58 $