[GRASS-user] v.rast.stats is error while executing: 'BEGIN TRANSACTION'

Hi all,
I’m new to GIS and also new to GRASS GIS. I want to zonal statistics from raster map rainfall interpolation(idw) on basin vector polygon. I used v.rast.stats. But there are problems

v.rast.stats -c vector=basin_250@PERMANENT raster=rainfall_idw@PERMANENT colprefix=z
Updating the database …
DBMI-DBF driver error:
SQL parser error: syntax error, unexpected NAME processing
‘BEGIN’
in statement:
BEGIN TRANSACTION
Error in db_execute_immediate()
ERROR: Error while executing: ‘BEGIN TRANSACTION’

Thank you.

Chingchai Humhong
Regional Center of Geo-Informatics and
Space Technology, Lower Northern Region
Naresuan University, Phitsanulok, Thailand. 65000
Lat:16.742496, Lon:100.191605

On Wed, Oct 15, 2014 at 6:16 PM, chingchai humhong
<chingchai.h@gmail.com> wrote:

Hi all,
I'm new to GIS and also new to GRASS GIS.

Welcome here!

I want to zonal statistics from
raster map rainfall interpolation(idw) on basin vector polygon. I used
v.rast.stats. But there are problems

v.rast.stats -c vector=basin_250@PERMANENT raster=rainfall_idw@PERMANENT
colprefix=z
Updating the database ...
DBMI-DBF driver error:
SQL parser error: syntax error, unexpected NAME processing
'BEGIN'
in statement:
BEGIN TRANSACTION
Error in db_execute_immediate()
ERROR: Error while executing: 'BEGIN TRANSACTION'

Thank you.

ok, the issue is that the DBF driver does not support SQL
transactions. I thought that this would be automatically handled.
I just tried on my system with the DBF driver and did not came across
this issue.

Which GRASS GIS version do you use on which operating system?

Markus

Hi Markus.
Thanks for your reply.
I used GRASS GIS version 6.4.4 on Ubuntu.

Chingchai

···

2014-10-20 4:54 GMT+07:00 Markus Neteler <neteler@osgeo.org>:

On Wed, Oct 15, 2014 at 6:16 PM, chingchai humhong
<chingchai.h@gmail.com> wrote:

Hi all,
I’m new to GIS and also new to GRASS GIS.

Welcome here!

I want to zonal statistics from
raster map rainfall interpolation(idw) on basin vector polygon. I used
v.rast.stats. But there are problems

v.rast.stats -c vector=basin_250@PERMANENT raster=rainfall_idw@PERMANENT
colprefix=z
Updating the database …
DBMI-DBF driver error:
SQL parser error: syntax error, unexpected NAME processing
‘BEGIN’
in statement:
BEGIN TRANSACTION
Error in db_execute_immediate()
ERROR: Error while executing: ‘BEGIN TRANSACTION’

Thank you.

ok, the issue is that the DBF driver does not support SQL
transactions. I thought that this would be automatically handled.
I just tried on my system with the DBF driver and did not came across
this issue.

Which GRASS GIS version do you use on which operating system?

Markus

Chingchai Humhong
Regional Center of Geo-Informatics and
Space Technology, Lower Northern Region
Naresuan University Phitsanulok 65000
Lat:16.742496, Lon:100.191605

Mobile: 08-4624-6278

Blog: http://nu-gis.blogspot.com
Website: http://www.cgistln.nu.ac.th

Dear Markus.
Many thanks for your reply.
I am master student in Thailand,
recently, I learning open source software and using OSGeolive 8. So, in OSGeolive 8 it had GRASS GIS version 6.4.4 on Ubuntu.

···

2014-10-20 9:36 GMT+07:00 chingchai humhong <chingchai.h@gmail.com>:

Hi Markus.
Thanks for your reply.
I used GRASS GIS version 6.4.4 on Ubuntu.

Chingchai

Chingchai Humhong
Regional Center of Geo-Informatics and
Space Technology, Lower Northern Region
Naresuan University Phitsanulok 65000
Lat:16.742496, Lon:100.191605

Mobile: 08-4624-6278

Blog: http://nu-gis.blogspot.com
Website: http://www.cgistln.nu.ac.th

2014-10-20 4:54 GMT+07:00 Markus Neteler <neteler@osgeo.org>:

On Wed, Oct 15, 2014 at 6:16 PM, chingchai humhong
<chingchai.h@gmail.com> wrote:

Hi all,
I’m new to GIS and also new to GRASS GIS.

Welcome here!

I want to zonal statistics from
raster map rainfall interpolation(idw) on basin vector polygon. I used
v.rast.stats. But there are problems

v.rast.stats -c vector=basin_250@PERMANENT raster=rainfall_idw@PERMANENT
colprefix=z
Updating the database …
DBMI-DBF driver error:
SQL parser error: syntax error, unexpected NAME processing
‘BEGIN’
in statement:
BEGIN TRANSACTION
Error in db_execute_immediate()
ERROR: Error while executing: ‘BEGIN TRANSACTION’

Thank you.

ok, the issue is that the DBF driver does not support SQL
transactions. I thought that this would be automatically handled.
I just tried on my system with the DBF driver and did not came across
this issue.

Which GRASS GIS version do you use on which operating system?

Markus

Chingchai Humhong
Regional Center of Geo-Informatics and
Space Technology, Lower Northern Region

Naresuan University Phitsanulok 65000
Lat:16.742496, Lon:100.191605

Mobile: 08-4624-6278

Blog: http://nu-gis.blogspot.com
Website: http://www.cgistln.nu.ac.th

On Sun, Oct 19, 2014 at 11:54 PM, Markus Neteler <neteler@osgeo.org> wrote:

On Wed, Oct 15, 2014 at 6:16 PM, chingchai humhong
<chingchai.h@gmail.com> wrote:

Hi all,
I'm new to GIS and also new to GRASS GIS.

Welcome here!

I want to zonal statistics from
raster map rainfall interpolation(idw) on basin vector polygon. I used
v.rast.stats. But there are problems

v.rast.stats -c vector=basin_250@PERMANENT raster=rainfall_idw@PERMANENT
colprefix=z
Updating the database ...
DBMI-DBF driver error:
SQL parser error: syntax error, unexpected NAME processing
'BEGIN'
in statement:
BEGIN TRANSACTION
Error in db_execute_immediate()
ERROR: Error while executing: 'BEGIN TRANSACTION'

Thank you.

ok, the issue is that the DBF driver does not support SQL
transactions. I thought that this would be automatically handled.

I was able to reproduce the issue.

I'm trying to address that now in
http://trac.osgeo.org/grass/ticket/2457

Markus

Dear Chingchai,

sorry for the delay. I have fixed the script (at least it no longer
fails in my tests here). Please try the updated script from here:
https://svn.osgeo.org/grass/grass/branches/releasebranch_6_4/scripts/v.rast.stats/v.rast.stats

Comment: Instead of trying to add SQL TRANSACTIONS to the DBF driver,
I have now simply conditionalized it in r63789. This fixed script will
ship with the future GRASS GIS 6.4.5.

Markus

On Wed, Oct 22, 2014 at 12:08 PM, Markus Neteler <neteler@osgeo.org> wrote:

On Sun, Oct 19, 2014 at 11:54 PM, Markus Neteler <neteler@osgeo.org> wrote:

On Wed, Oct 15, 2014 at 6:16 PM, chingchai humhong
<chingchai.h@gmail.com> wrote:

Hi all,
I'm new to GIS and also new to GRASS GIS.

Welcome here!

I want to zonal statistics from
raster map rainfall interpolation(idw) on basin vector polygon. I used
v.rast.stats. But there are problems

v.rast.stats -c vector=basin_250@PERMANENT raster=rainfall_idw@PERMANENT
colprefix=z
Updating the database ...
DBMI-DBF driver error:
SQL parser error: syntax error, unexpected NAME processing
'BEGIN'
in statement:
BEGIN TRANSACTION
Error in db_execute_immediate()
ERROR: Error while executing: 'BEGIN TRANSACTION'

Thank you.

ok, the issue is that the DBF driver does not support SQL
transactions. I thought that this would be automatically handled.

I was able to reproduce the issue.

I'm trying to address that now in
http://trac.osgeo.org/grass/ticket/2457

Markus

Dear Markus Neteler,

Thank you for getting back to me.
I truly appreciate your help in resolving the problem.

Best regards,

Chingchai

···

2014-12-28 6:56 GMT+07:00 Markus Neteler <neteler@osgeo.org>:

Dear Chingchai,

sorry for the delay. I have fixed the script (at least it no longer
fails in my tests here). Please try the updated script from here:
https://svn.osgeo.org/grass/grass/branches/releasebranch_6_4/scripts/v.rast.stats/v.rast.stats

Comment: Instead of trying to add SQL TRANSACTIONS to the DBF driver,
I have now simply conditionalized it in r63789. This fixed script will
ship with the future GRASS GIS 6.4.5.

Markus

On Wed, Oct 22, 2014 at 12:08 PM, Markus Neteler <neteler@osgeo.org> wrote:

On Sun, Oct 19, 2014 at 11:54 PM, Markus Neteler <neteler@osgeo.org> wrote:

On Wed, Oct 15, 2014 at 6:16 PM, chingchai humhong
<chingchai.h@gmail.com> wrote:

Hi all,
I’m new to GIS and also new to GRASS GIS.

Welcome here!

I want to zonal statistics from
raster map rainfall interpolation(idw) on basin vector polygon. I used
v.rast.stats. But there are problems

v.rast.stats -c vector=basin_250@PERMANENT raster=rainfall_idw@PERMANENT
colprefix=z
Updating the database …
DBMI-DBF driver error:
SQL parser error: syntax error, unexpected NAME processing
‘BEGIN’
in statement:
BEGIN TRANSACTION
Error in db_execute_immediate()
ERROR: Error while executing: ‘BEGIN TRANSACTION’

Thank you.

ok, the issue is that the DBF driver does not support SQL
transactions. I thought that this would be automatically handled.

I was able to reproduce the issue.

I’m trying to address that now in
http://trac.osgeo.org/grass/ticket/2457

Markus

Chingchai Humhong
Regional Center of Geo-Informatics and
Space Technology, Lower Northern Region
Naresuan University Phitsanulok 65000
Lat:16.742496, Lon:100.191605

Mobile: 08-4624-6278

Blog: http://nu-gis.blogspot.com
Website: http://www.cgistln.nu.ac.th