Bug report #470
adding a column to GRASS vector corrupts it
Status: | Closed | ||
---|---|---|---|
Priority: | Low | ||
Assignee: | - | ||
Category: | GRASS | ||
Affected QGIS version: | master | Regression?: | No |
Operating System: | All | Easy fix?: | No |
Pull Request or Patch supplied: | No | Resolution: | fixed/implemented |
Crashes QGIS or corrupts data: | No | Copied to github as #: | 10529 |
Description
QGIS SVN 6277, GRASS 6.3 CVS 18.12.2006 ~3:00 PM
Plugins -> GRASS
1. 'Open mapset' "spearfish60/PERMANENT"
2. 'Create new Grass vector' "testing"
3. digitise one feature (eg. a point) using default 'Next not used' category mode
4. switch to 'Table', add one column (any type, any name)
5. 'Edit attributes' and click on the point you've digitised in point 3
6. you get "WARNING: ATTRIBUTES MISSING" and you can't edit the attribute you set the column for in step 4
Trying to 'Update' the table yields:
DBMI-DBF driver error: SQL parser error in statement: update test set WARNING: ATTRIBUTES MISSING = 'WARNING: ATTRIBUTES MISSING' where cat = 1 Error in db_execute_immediate()
Closing the GRASS Edit and opening it back, as well as removing the GRASS vector from layers list and adding it back doesn't help. If you quit QGIS and start it back, and then add the GRASS vector in question it is added but nothing is rendered.
You can display and query the vector in GRASS tough, but you can't edit the attribute you have added in step 4 (it is not listed), both in v.digit and d.what.vect -e. Strange is that v.info -c reports this column OK and v.db.connect -p says the database link is OK.
IOW, the GRASS vectro in question is corruputed.
Maciek
P.S.
All references to GRASS should be in capital letters. Please get rid of "Grass".
History
#1 Updated by anonymous - almost 18 years ago
This is not bug but feature. First you create an element with a category but a table does not exist yet so there is no record created in the table. Then when the table exists QGIS cannot find appropriate record in the table so it says "WARNING: ATTRIBUTES MISSING". That is true, the record in the table for the element's category is missing.
That may be intended or not.
I agrree that this can be inconvenient and I suggest two mprovements:
1) when the table is created and elemts with categories of that layer exist
QGIS should ask user if new records should be inserted for them in the table
2) in the 'GRASS Attributes dialog' it should be more clearly explained that
a record in table is missing and there should be a button for adding a new
record to the table for that element
Both improvements canot be done in 0.8 so I am going to change this ticket
to enhancement/0.9.
Radim
PS: Changing this ticket back to 0.8/critical bug will only result in
changing owner to nobody by me.
#2 Updated by Giovanni Manghi almost 13 years ago
- Target version changed from Version 1.7.0 to Version 1.7.4
#3 Updated by Paolo Cavallini almost 13 years ago
- Crashes QGIS or corrupts data set to No
- Affected QGIS version set to master
- Pull Request or Patch supplied set to No
- Assignee deleted (
Lorenzo Masini)
#4 Updated by Paolo Cavallini over 12 years ago
- Target version changed from Version 1.7.4 to Version 1.8.0
#5 Updated by Paolo Cavallini about 12 years ago
- Target version changed from Version 1.8.0 to Version 2.0.0
#6 Updated by Jürgen Fischer over 10 years ago
- Target version changed from Version 2.0.0 to Future Release - Lower Priority
#7 Updated by Paolo Cavallini about 9 years ago
- Status changed from Open to Feedback
Superseded by the new GRASS7 editing. Probably it should be closed.
#8 Updated by Giovanni Manghi about 9 years ago
- Resolution set to fixed/implemented
- Status changed from Feedback to Closed