Feature request #10024

Drag and Drop CSV file

Added by Antonio Locandro almost 10 years ago. Updated almost 6 years ago.

Status:Feedback
Priority:Normal
Assignee:-
Category:Unknown
Pull Request or Patch supplied:No Resolution:
Easy fix?:No Copied to github as #:18510

Description

It would be nice if one can Drag and Drop CSV files either directly from system or from Browser and QGIS would try to detect all the required fields in the Create a Layer from Delimited text File, that way one would only need to review things before pressing OK

History

#1 Updated by Regis Haubourg almost 10 years ago

1 for the feature request.
that means dropping ogr csv support and use only csv delimiter c
+ provider.. and that would remove a bad redondancy in QGIS providers.
ogr csv support is too limited compared to plugin's one.

#2 Updated by Giovanni Manghi almost 7 years ago

  • Easy fix? set to No

#3 Updated by Jürgen Fischer over 6 years ago

  • Category set to Unknown

#4 Updated by Antonio Locandro almost 6 years ago

Checked and although I can drag and drop it, I was expecting the behaviour to be similar to when you add the csv through the dedicated tool and open the parameters to have a spatial layer from CSV

#5 Updated by Giovanni Manghi almost 6 years ago

  • Status changed from Open to Feedback

Antonio Locandro wrote:

Checked and although I can drag and drop it, I was expecting the behaviour to be similar to when you add the csv through the dedicated tool and open the parameters to have a spatial layer from CSV

I really think that the correct behavior is the actual one: d&d you gets a geometryless table, using the delimited text provider button you get a spatial table.

#6 Updated by Antonio Locandro almost 6 years ago

I see why this would be good, I think we can close then this

#7 Updated by Andy Harfoot almost 6 years ago

From http://www.gdal.org/drv_csv.html

"Starting with GDAL 2.1, it is possible to directly specify the potential names of the columns that can contain X/longitude and Y/latitude with the X_POSSIBLE_NAMES and Y_POSSIBLE_NAMES open option."

These could be hard coded into the QGIS OGR CSV load function, or set via a preference, meaning that for CSVs containing appropriately named spatial columns, the geometry would be read automatically on drag and drop.

Alternatively, a context menu command could be added for text files 'Open as spatial delimited text', routing the load via the dialog.

I would like to keep this request open - the current behaviour of CSV drag and drop lags behind that of other formats

Also available in: Atom PDF