[GRASS-user] vector maps - help needed - part 2

Hi all,

sorry, but I still don't understand the vector/database handling of grass completely. At the moment I use dbf files, but this seems not to be very flexible. It seems also that not all vector data is stored in the dbf files. When I import for example a shapefile into grass, are all nodes of the lines imported to dbf? I think no because I have an other folder on my computer which is called "vector" but what are the files "cidx,coor,dvln,head,hist,topo"?

As you can see, I'm really confused, what this database stuff is for when all data is still stored somewhere else.

I hope that somebody can help me and explain me the idea of vector/database handling.

Thanks
Wolfgang

On Tue, 30 May 2006 22:10:42 +0200
Wolfgang <wollez@gmx.net> wrote:

Hi all,

sorry, but I still don't understand the vector/database handling of
grass completely. At the moment I use dbf files, but this seems not
to be very flexible. It seems also that not all vector data is stored
in the dbf files.

Only attributes of vector features (point,line,centroid etc.) are
stored in the table (no matter what DB backend in Grass).

Note that a feature to have an entry in the table has got to have a
category first (see v.category).

When I import for example a shapefile into grass,
are all nodes of the lines imported to dbf?

No. One line is one, whole vector feature. If you need each node to have
separate table entry, use v.to.points -v, then v.to.db.

I think no because I have
an other folder on my computer which is called "vector" but what are
the files "cidx,coor,dvln,head,hist,topo"?

As you can see, I'm really confused, what this database stuff is for
when all data is still stored somewhere else.

I hope that somebody can help me and explain me the idea of
vector/database handling.

v.in.ogr, as well as many other Grass modules that output a new vector
layer, will setup categories for features and upload them into a key
"CAT" column (it could be any other name though, see v.db.connect)
along with their attributes respectively.

Read your grass-6.1.cvs/docs/html/vectorintro.html too.

I hope it helps.

Best,
Maciek

--------------------
W polskim Internecie s? setki milion?w stron. My przekazujemy Tobie tylko najlepsze z nich!
http://katalog.panoramainternetu.pl/

> sorry, but I still don't understand the vector/database handling of
> grass completely. At the moment I use dbf files, but this seems not
> to be very flexible.

try sqlite

> I think no because I have
> an other folder on my computer which is called "vector" but what are
> the files "cidx,coor,dvln,head,hist,topo"?

see
http://freegis.org/cgi-bin/viewcvs.cgi/*checkout*/grass6/doc/vector/vector.html?rev=HEAD&content-type=text/html
http://freegis.org/cgi-bin/viewcvs.cgi/grass6/doc/vector/

> As you can see, I'm really confused, what this database stuff is
> for when all data is still stored somewhere else.

it's for attributes (road name, surface type, etc.). Actual coordinates
and topology are stored in $MAPSET/vector/

The two are linked by category number.

> I hope that somebody can help me and explain me the idea of
> vector/database handling.

v.in.ogr, as well as many other Grass modules that output a new vector
layer, will setup categories for features and upload them into a key
"CAT" column (it could be any other name though, see v.db.connect)
along with their attributes respectively.

Read your grass-6.1.cvs/docs/html/vectorintro.html too.

also
http://grass.itc.it/grass61/manuals/html61_user/databaseintro.html
http://grass.itc.it/grass61/manuals/html61_user/sql.html
http://grass.itc.it/grass57/tutorial/links.html

I hope it helps.

ditto

Hamish