[GRASS-user] sql

Markus Neteler neteler at osgeo.org
Wed Sep 2 15:05:36 EDT 2009


On Wed, Sep 2, 2009 at 8:43 PM, Matthew Mulbrandon<mulbran at hotmail.com> wrote:
> Hello,
>
> I am trying to do a simple inner join on two tables (both dbf and in the
> same directory)
> tenn_county_all_b
> ddistance

Matthew,

AFAIK joins are not supported with DBF. You could use the SQLite
driver to do this.

- make a new mapset
- run db.connect to define SQLite as default backend (see db.connect manual)
- g.copy the maps from the original mapset and GRASS will convert the
  tables into SQLite
- do the join [1]

Of course also PostgreSQL, mySQL etc are fine.

Hope this helps,
Markus

[1] I have made an Addons script for this:
     http://grass.osgeo.org/wiki/GRASS_AddOns#db.join


More information about the grass-user mailing list