[GRASS-SVN] r42959 - grass/trunk/scripts/v.db.droptable
svn_grass at osgeo.org
svn_grass at osgeo.org
Sun Aug 1 05:00:40 EDT 2010
Author: mmetz
Date: 2010-08-01 09:00:40 +0000 (Sun, 01 Aug 2010)
New Revision: 42959
Modified:
grass/trunk/scripts/v.db.droptable/v.db.droptable.py
Log:
find grass.vector_layer_db, use the vector's database and driver
Modified: grass/trunk/scripts/v.db.droptable/v.db.droptable.py
===================================================================
--- grass/trunk/scripts/v.db.droptable/v.db.droptable.py 2010-08-01 03:16:39 UTC (rev 42958)
+++ grass/trunk/scripts/v.db.droptable/v.db.droptable.py 2010-08-01 09:00:40 UTC (rev 42959)
@@ -48,7 +48,7 @@
import sys
import os
-from grass.script import core as grass
+import grass.script as grass
def main():
force = flags['f']
@@ -85,7 +85,8 @@
grass.message(_("Dropping table <%s>...") % table)
- if grass.write_command('db.execute', stdin = "DROP TABLE %s" % table, input = '-') != 0:
+ if grass.write_command('db.execute', stdin = "DROP TABLE %s" % table, input = '-',
+ database = database, driver = driver) != 0:
grass.fatal(_("An error occured while running db.execute"))
grass.run_command('v.db.connect', flags = 'd', map = map, layer = layer)
More information about the grass-commit
mailing list