[GRASS-dev] [GRASS GIS] #4009: 'where' option in v.to.rast can select wrong feature for raster attribute, in areas where features overlap

GRASS GIS trac at osgeo.org
Fri Dec 13 01:07:02 PST 2019


#4009: 'where' option in v.to.rast can select wrong feature for raster attribute,
in areas where features overlap
------------------------+---------------------------------
  Reporter:  florisvdh  |      Owner:  grass-dev@…
      Type:  defect     |     Status:  new
  Priority:  normal     |  Milestone:
 Component:  Vector     |    Version:  svn-releasebranch76
Resolution:             |   Keywords:  v.to.rast sql where
       CPU:  x86-64     |   Platform:  Linux
------------------------+---------------------------------

Comment (by florisvdh):

 Below are a few characteristics of the map. Note, the actual values of
 {{{field 1}}} are not 'x1', 'x2' etc. but specific codes. Given the size
 of the data, I truncated the output.

 {{{
 $ v.info polygon_layer -c
 Displaying column types/names for database connection of layer <1>:
 INTEGER|cat
 TEXT|field1
 DOUBLE PRECISION|field2

 $ v.db.select map=polygon_layer | wc -l
 85051

 $ v.db.select map=polygon_layer where="field1 LIKE 'rbbhc'" | wc -l
 4720

 $ v.db.select map=polygon_layer where="field1 LIKE 'rbbhc'" | head
 cat|field1|field2
 132|rbbhc|20
 146|rbbhc|70
 151|rbbhc|30
 152|rbbhc|30
 153|rbbhc|30
 154|rbbhc|30
 155|rbbhc|30
 156|rbbhc|30
 157|rbbhc|30
 }}}

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



More information about the grass-dev mailing list