[GRASS5] 5.7: dbf driver and 'double' initialization
Markus Neteler
neteler at itc.it
Mon Sep 6 22:55:50 EDT 2004
There seems to be a problem with the initialization of
double (maybe also int) type in the DBF driver of 5.7:
echo "ALTER TABLE dourokukan ADD COLUMN forward double" | db.execute
echo "ALTER TABLE dourokukan ADD COLUMN backward double" | db.execute
echo "ALTER TABLE dourokukan ADD COLUMN length double" | db.execute
dbfdump dourokukan.dbf
cat label forward backward length
1 s3m (NULL) (NULL) (NULL)
3 e3.0m (NULL) (NULL) (NULL)
5 e5.5m (NULL) (NULL) (NULL)
13 s13.0 (NULL) (NULL) (NULL)
15 yes (NULL) (NULL) (NULL)
I assume that it should be set to zero (0).
At least I don't know how to access these (NULL) values in
a later SQL update :
echo "UPDATE dourokukan SET forward=50 WHERE forward=0" | db.execute
echo "SELECT * FROM dourokukan" | db.select
cat|label|forward|backward|length
1|s3m|||
3|e3.0m|||
5|e5.5m|||
13|s13.0|||
15|yes|||
Any advice is welcome,
Markus
More information about the grass-dev
mailing list