[GRASS5] counting number of vector points in same position?
Radim Blazek
radim.blazek at gmail.com
Mon Aug 22 03:28:54 EDT 2005
On 8/16/05, Markus Neteler <neteler at itc.it> wrote:
> # upload number of identical vector points to attribute table:
> v.to.db triple_simple_multi option=query layer=2 qlayer=1 column=count
> Reading data trom the map ... 100%
> Querying database ... 100%
> DBMI-DBF driver error:
> SQL parser error in statement:
> SELECT (null) FROM triple_simple_multi WHERE cat = 2 OR cat = 1 OR cat = 3
> Error in db_open_select_cursor()
>
> ERROR: Cannot open cursor: 'SELECT (null) FROM triple_simple_multi WHERE
> cat = 2 OR cat = 1 OR cat = 3'
>
qcolumn option is missing, it should be 'count(*) in this case, but it can be
expression supported by database driver, for example sum(colum_in_layer_1).
Unfortunately count and sum is not supported by dbf driver, so it is necessary
to use postgres.
Radim
More information about the grass-dev
mailing list