[GRASS-dev] [GRASS GIS] #1534: vector_db_select fails with kwargs
GRASS GIS
trac at osgeo.org
Fri Jan 13 07:32:51 EST 2012
#1534: vector_db_select fails with kwargs
-------------------------+--------------------------------------------------
Reporter: artegion | Owner: grass-dev@…
Type: defect | Status: new
Priority: critical | Milestone: 6.4.2
Component: Python | Version: unspecified
Keywords: | Platform: All
Cpu: Unspecified |
-------------------------+--------------------------------------------------
in lib/python/vector.py, at line 205, fs option makes trouble if kwargs is
not None
>00202 ret = read_command('v.db.select',
>00203 map = map,
>00204 layer = layer,
>00205 fs = '|', **kwargs)
i.e. grass.vector_select('lakes', where='cat in (1,2,3,4,5)')
because start_command transforms | character into shell pipe
""where=cat in (1,3,4,5)"" non è riconosciuto come comando interno o
esterno,
un programma eseguibile o un file batch.
ERRORE: vector_select() failed
possible solutions:
1) fs=| is default option in v.db.select so
00202 ret = read_command('v.db.select',
00203 map = map,
00204 layer = layer,
00205 **kwargs) # fs = '|', removed
will work
2) change | with another character ....
--
Ticket URL: <http://trac.osgeo.org/grass/ticket/1534>
GRASS GIS <http://grass.osgeo.org>
More information about the grass-dev
mailing list