[GRASS-user] db.execute where condition

frans-joost fjboogert at gmail.com
Sun Mar 6 07:10:43 EST 2011

Dear GRASS users,

I have imported a table titled landuse_tabe with the db.in.ogr command.
I want to do the following with the table:
Add a column named FEATURE_ID
and add values to the column.
To add the values to the column I use:

echo 'UPDATE landuse_table SET FEATURE_ID='1' WHERE
FEATURE='Grazing_land'|db.execute driver=dbf database=$database

I get the following error:

DBMI-DBF driver error:
Column 'Grazing_land' not found
Incompatible types in WHERE condition.
Error in selecting rows
Error in db_execute_immediate()

ERROR: Error while executing: 'UPDATE landuse_table SET FEATURE_ID=1 WHERE
If I leave out the WHERE condition the command works fine.
Is it not possible to use SQL where conditions with dbf databases?
The site http://grass.fbk.eu/grass62/manuals/html62_user/grass-dbf.html says
it is possible to use this command.
Can anyone explain to me what I'm doing wrong?

Thank you in advance,
Frans-Joost Boogert

View this message in context: http://osgeo-org.1803224.n2.nabble.com/db-execute-where-condition-tp6094088p6094088.html
Sent from the Grass - Users mailing list archive at Nabble.com.

More information about the grass-user mailing list