Feature request #3373

fTools buffer geoprocessing error with certain data

Added by samrae29 - over 9 years ago. Updated over 3 years ago.

Status:Closed
Priority:Low
Assignee:cfarmer -
Category:Processing/QGIS
Pull Request or Patch supplied: Resolution:fixed
Easy fix?: Copied to github as #:13433

Description

Buffering fails if shapefile has two columns with the same name. This error did not occur in previous QGIS releases (v1.2 ?), but has been found in QGIS 1.6.

Steps:
1. Open buffer(s) dialog: Vector > Geoprocessing tools > Buffer(s)
2. Input vector layer selected has two columns with the identical column name.
3. Choose output file and buffer distance e.g. 0.0005, and leave other defaults.
4. For "Would you like to add the new layer to TOC?", click Yes
5. Geoprocessing dialog then returns:
Error loadings output shape files
C:/QuantumGIS-1.6/foo.shp

Ticket request:
1. Short-term. A more user-friendly error message explaining that there is a problem with duplicate column names
2. Buffer tool to handle shapefiles with duplicate column names?

Submitted by: (irc: samrae)

sample_data.tar.gz - Error replicated using this dataset. Duplicate column name 'SOURCE_PRO' (197 KB) samrae29 -, 2010-12-28 10:58 AM

History

#1 Updated by Giovanni Manghi over 9 years ago

are two columns with the same name allowed?

#2 Updated by Tim Sutton over 9 years ago

Replying to [comment:1 lutra]:

are two columns with the same name allowed?

According to the spec as far as I know you may not have duplicate column names, but users don't always follow the spec and the buffer tool should at least give the user some feedback as to why creation of the buffer failed.

Tim

#3 Updated by cfarmer - over 9 years ago

  • Resolution set to fixed
  • Status changed from Open to Closed

This ticket is actually a duplicate of #3148, which has been closed as of c08e1a42 (SVN r15386). QgsVectorFileWriter should now handle duplicate names more gracefully, and where it does not, fTools now issues an error message.

As always, please update and test to confirm this issues has been resolved. If not, please reopen the ticket.

Regards,

Carson

#4 Updated by Giovanni Manghi over 3 years ago

The "ftools" category is being removed from the tracker, changing the category of this ticket to "Processing/QGIS" to not leave the category orphaned.

Also available in: Atom PDF