[GRASS-dev] Re: [GRASS GIS] #1055: db.select can´t found columns generated by v.rast.stats with dbf driver

GRASS GIS trac at osgeo.org
Wed May 5 12:48:51 EDT 2010


#1055: db.select can´t found columns generated by v.rast.stats with dbf driver
---------------------------+------------------------------------------------
  Reporter:  jeleniste     |       Owner:  grass-dev at lists.osgeo.org
      Type:  defect        |      Status:  new                      
  Priority:  normal        |   Milestone:  6.4.0                    
 Component:  Database      |     Version:  6.4.0 RCs                
Resolution:                |    Keywords:  dbf, db.select           
  Platform:  MSWindows XP  |         Cpu:  Unspecified              
---------------------------+------------------------------------------------
Comment (by martinl):

 Replying to [ticket:1055 jeleniste]:
 > if I try to use in sql parameter in where clausule column generated by
 v.rast.stats it return me error, column cant be found, but is presented in
 table output (if not used in where clausule), using in list of columns for
 select returns me error to

 {{{
 g.copy vect=geology,geo --o
 v.rast.stats vector=geo raster=elevation colprefix=elev --v
 }}}

 {{{
 v.info -c geo | grep elevINTEGER|elev_n
 DOUBLE PRECISION|elev_min
 DOUBLE PRECISION|elev_max
 DOUBLE PRECISION|elev_range
 DOUBLE PRECISION|elev_mean
 DOUBLE PRECISION|elev_stdde
 DOUBLE PRECISION|elev_varia
 DOUBLE PRECISION|elev_cf_va
 DOUBLE PRECISION|elev_sum
 }}}

 {{{
 v.db.select map=geo columns=cat,elev_n,elev_min where="elev_n not NULL"
 cat|elev_n|elev_min
 217|725565|80.929474
 262|198686|75.525719
 270|689296|55.578793
 405|253653|90.39637
 583|21656|118.640244
 720|4807|102.848068
 766|7086|113.913361
 862|61710|91.674515
 910|45044|73.698929
 921|12563|115.666611
 945|9|124.292007
 946|4053|75.179901
 948|872|118.361198
 }}}

 Seems to work... Did I understood well?

 Martin

-- 
Ticket URL: <http://trac.osgeo.org/grass/ticket/1055#comment:2>
GRASS GIS <http://grass.osgeo.org>


More information about the grass-dev mailing list