Opened 13 years ago
Closed 8 years ago
#1494 closed defect (fixed)
v.in.ogr key flag does not change category values and you loose connection between features and attributes
Reported by: | mlennert | Owned by: | martinl |
---|---|---|---|
Priority: | major | Milestone: | 7.0.5 |
Component: | Vector | Version: | svn-trunk |
Keywords: | v.in.ogr | Cc: | grass-dev@… |
CPU: | Unspecified | Platform: | Unspecified |
Description
Currently, v.in.ogr internally creates cat values for an imported vector. It would be great if one could tell v.in.ogr to use an existing attribute column as cat value, including when importing using the -t flag to not create any attribute table within grass.
Change History (11)
comment:1 by , 13 years ago
Keywords: | v.in.ogr added |
---|---|
Milestone: | → 7.0.0 |
comment:2 by , 9 years ago
Milestone: | 7.0.0 → 7.0.5 |
---|
follow-up: 4 comment:3 by , 8 years ago
Resolution: | → worksforme |
---|---|
Status: | new → closed |
follow-up: 6 comment:4 by , 8 years ago
Priority: | normal → major |
---|---|
Resolution: | worksforme |
Status: | closed → reopened |
Summary: | wish: v.in.ogr add possibility to use existing attribute column as category value, including with -t option → v.in.ogr key flag does not change category values and you loose connection between features and attributes |
Type: | enhancement → defect |
Replying to martinl:
v.in.ogr
in GRASS 7 haskey
parameter which allows you to define key column,
Yes, but apparently it doesn't work:
g.copy vect=boundary_county,bc v.db.addcol bc col="newcat int" v.db.addcolumn bc col="newcat int" v.db.update bc col=newcat qcol=cat+1000 v.out.ogr bc out=bc v.in.ogr bc/bc.shp out=bc_test key=newcat v.db.connect -p bc_test v.db.univar bc_test col=newcat v.category bc_test op=report
You will see that the db connection is correctly defined with the 'newcat' column as the key, but the features' category values are still automatically generated from 1. You thus loose the connection between features and attributes !
Redefining this as a bug and reopening.
Moritz
follow-up: 8 comment:6 by , 8 years ago
comment:7 by , 8 years ago
Cc: | added |
---|---|
Owner: | changed from | to
Status: | reopened → new |
comment:8 by , 8 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
comment:9 by , 8 years ago
Resolution: | fixed |
---|---|
Status: | closed → reopened |
v.in.ogr
in GRASS 7 haskey
parameter which allows you to define key column,